block ip address via .net

Job ID: 32357788

Budget: $10 – $30 USD

Hi
I need a .net function that gets an ip address and blocks it in the windows firewall
if there's a rule named "my blacklist" it should add it to that same rule
otherwise create a new rule with name "my blacklist" and add inputted ip to the list of blocked ips
function gets 1 parameter only (the ip address) and does all the work
code should work in asp.net managed code (no process.start or winapi/pinvokes please)
thanks
Related categories: .NET Firewall