cancel
Showing results for 
Search instead for 
Did you mean: 
Post a Question
Eric_Speake
Nickel

Listing the members of a network group

Jump to solution

We are doing audits and cleanup of the network objects in our policy rules. I need to provide a list of servers in a specific network group. I have tried "$MDS_FWDIR/scripts/web_api_show_package.sh -k <policy_name>" but that seems to work only with the VS packages. I am running R80.10 on the management server.

Thanks,

Eric

Senior Systems Administrator

1 Solution

Accepted Solutions
Maik
Silver

Re: Listing the members of a network group

Jump to solution

I've written a small python script that exports all groups and the related hosts within it (host, network, address range and security gateway objects) as a csv file. It also shows empty groups, that were possible forgotten about. The script works only for IPv4 objects!

# example csv header:
# groupname,groupuid,membername,membertype,memberip,membersubnetmask,memberuid

You can use the script and filter for the required group in the related group name column. The script usage is shown by specifying the -h parameter. Just make sure that you copy the whole folder within the zip as the subfolder "mgmt_api_lib" is also required (the script has only been tested with Python 2.7 - which is preinstalled within R80).

3 Replies
Maik
Silver

Re: Listing the members of a network group

Jump to solution

I've written a small python script that exports all groups and the related hosts within it (host, network, address range and security gateway objects) as a csv file. It also shows empty groups, that were possible forgotten about. The script works only for IPv4 objects!

# example csv header:
# groupname,groupuid,membername,membertype,memberip,membersubnetmask,memberuid

You can use the script and filter for the required group in the related group name column. The script usage is shown by specifying the -h parameter. Just make sure that you copy the whole folder within the zip as the subfolder "mgmt_api_lib" is also required (the script has only been tested with Python 2.7 - which is preinstalled within R80).

Admin
Admin

Re: Listing the members of a network group

Jump to solution

I'm going to move this to Developers (Code Hub)

0 Kudos
Employee++
Employee++

Re: Listing the members of a network group

Jump to solution

Very good work, Maik.

0 Kudos