Networking Forums

Networking Forums > Computer Networking > Windows Networking > programmatically finding out firewall profile in use

Reply
Thread Tools Display Modes

programmatically finding out firewall profile in use

 
 
Ajey
Guest
Posts: n/a

 
      11-16-2006, 03:22 PM
Hi,
I need to report on the firewall settings for a machine. I read that
Domain Profile is used when the machine is part of domain and Standard
Profile is used when in a workgroup. However, for W2k3 SP1 DC a Standard
profile is used instead of Domain Profile
(http://support.microsoft.com/kb/555381/en-us).

Is there a way to programmatically find out which profile is being used for
the firewall?

I had tried using the MS logic of 'Network Determination' from
http://www.microsoft.com/technet/com...uy/cg0504.mspx
In this case if I change the value of
HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\Curr entVersion\Group
Policy\History\NetworkName
manually still it is not reflected when the firewall UI is launched.

Is there a programmatic way of finding the profile being used?
Or I have to go with the assumption that a DC will always use Standard
Profile?

This is required because based on the profile I will read the registry
entries. (I want to avoid using any firewall APIs for reading the
configuration and read them directly from registry)

Thanks in advance.

Regards,
Ajey

 
Reply With Quote
 
 
 
 
Phillip Windell
Guest
Posts: n/a

 
      11-16-2006, 03:59 PM
"Ajey" <(E-Mail Removed)> wrote in message
news:860E6D26-FFA5-4286-B10D-(E-Mail Removed)...

> Is there a way to programmatically find out which profile is being used
> for
> the firewall?


The Firewall Setting dialog will show you that. Even if the firewall
settings are greyed out and won't let you change them, it will tell you the
GPO Profile being used. It is down at the bottom of the box.

You may also be interested in the GP Inventory Tool that is downloadable
from MS.

--
Phillip Windell [MCP, MVP, CCNA]
www.wandtv.com

The views expressed are my own (as annoying as they are), and not those of
my employer or anyone else associated with me.
-----------------------------------------------------


 
Reply With Quote
 
Ajey
Guest
Posts: n/a

 
      11-17-2006, 04:20 AM
Thanks Phillip.
But I need to find out the profile being used in my code and not through UI.

"Phillip Windell" wrote:

> "Ajey" <(E-Mail Removed)> wrote in message
> news:860E6D26-FFA5-4286-B10D-(E-Mail Removed)...
>
> > Is there a way to programmatically find out which profile is being used
> > for
> > the firewall?

>
> The Firewall Setting dialog will show you that. Even if the firewall
> settings are greyed out and won't let you change them, it will tell you the
> GPO Profile being used. It is down at the bottom of the box.
>
> You may also be interested in the GP Inventory Tool that is downloadable
> from MS.
>
> --
> Phillip Windell [MCP, MVP, CCNA]
> www.wandtv.com
>
> The views expressed are my own (as annoying as they are), and not those of
> my employer or anyone else associated with me.
> -----------------------------------------------------
>
>
>

 
Reply With Quote
 
Phillip Windell
Guest
Posts: n/a

 
      11-17-2006, 06:55 PM
Code?

That is not a question for networking people.
Ask in a Development Group


--
Phillip Windell [MCP, MVP, CCNA]
www.wandtv.com

The views expressed are my own (as annoying as they are), and not those of
my employer or anyone else associated with me.
-----------------------------------------------------




"Ajey" <(E-Mail Removed)> wrote in message
news:860E6D26-FFA5-4286-B10D-(E-Mail Removed)...
> Hi,
> I need to report on the firewall settings for a machine. I read that
> Domain Profile is used when the machine is part of domain and Standard
> Profile is used when in a workgroup. However, for W2k3 SP1 DC a Standard
> profile is used instead of Domain Profile
> (http://support.microsoft.com/kb/555381/en-us).
>
> Is there a way to programmatically find out which profile is being used
> for
> the firewall?
>
> I had tried using the MS logic of 'Network Determination' from
> http://www.microsoft.com/technet/com...uy/cg0504.mspx
> In this case if I change the value of
> HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\Curr entVersion\Group
> Policy\History\NetworkName
> manually still it is not reflected when the firewall UI is launched.
>
> Is there a programmatic way of finding the profile being used?
> Or I have to go with the assumption that a DC will always use Standard
> Profile?
>
> This is required because based on the profile I will read the registry
> entries. (I want to avoid using any firewall APIs for reading the
> configuration and read them directly from registry)
>
> Thanks in advance.
>
> Regards,
> Ajey
>



 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Switch firewall profile public <-> private in Server 2008/Vista Jeff Stark Windows Networking 0 02-27-2009 09:32 PM
Win2K8 clustering and Firewall profile ChielV Windows Networking 0 06-18-2008 01:34 PM
Transfer workstation profile (NT DC user profile to W2K3 Tys-Comuquest Windows Networking 1 05-05-2008 03:47 PM
Finding hidden firewall driver Oskar Busch Windows Networking 3 08-18-2006 02:47 PM
Need help finding a low cost hardware firewall device Mark Hobley Home Networking 2 08-03-2004 02:32 AM



1 2 3 4 5 6 7 8 9 10 11