Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C# .NET Network TCP/IP
Hye Everyone,
 
I need to know, if these things can be done and (if yes) how they can be done through C# code :
 
1. to detect if any firewall is running on System.
2. to detect if any particular port (let say 9001) is blocked (outbound/inbound)
and if yes; how to know if its outgoing blocked or incoming blocked.
3. to detect if my IP Address is blocked by ISP or not.
 

Please, do reply..
its urgent.
 
FYI : (My application is on .NET Framework 4.0 (VS 2010))
 
thanks in advance..
Posted 23-Mar-12 4:37am
Edited 23-Mar-12 4:52am
v2

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

  Permalink  
v4
Comments
DeepsMann at 26-Mar-12 3:43am
   
Thanks..
Can u please tell me how to use
 
INetFwMgr.IsPortAllowed
Shahin Khorshidnia at 26-Mar-12 9:23am
   
INetFWMgr is an interface and you can use Activator.
for example:
INetFwMgr mgr = (INetFwMgr)Activator.CreateInstance(NetFwMgrType);
 
For more detail look at the updated answer.
DeepsMann at 26-Mar-12 6:18am
   
Can i configure ip address of my system from my application???
Shahin Khorshidnia at 26-Mar-12 9:25am
   
Yes. and look at the updated solution for "How"
Shahin Khorshidnia at 26-Mar-12 9:26am
   
And also, if the solution and links help, You can accept the solution.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 8,284
1 Sergey Alexandrovich Kryukov 7,327
2 DamithSL 5,614
3 Manas Bhardwaj 4,986
4 Maciej Los 4,920


Advertise | Privacy | Mobile
Web02 | 2.8.1411023.1 | Last Updated 26 Mar 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100