Members of your organization can configure their profile visibility, which determines who can view their profile and invite them to join groups. Depending on your organization's security policies, it may be necessary for you, as an administrator, to be aware of who can view the complete profile information of your members. For organizations with a large number of members, manually reviewing and changing the profile visibility setting of each member can be challenging. ArcGIS Enterprise includes a Python script tool, ProfileVisibilityChanger.py, which generates an HTML report that lists all members and their profile visibility settings, and allows you to update them in bulk.
The ProfileVisibilityChanger.py script is in the <Portal for ArcGIS installation location>/tools/security directory. Run the script from the shell using the ProfileVisibilityChanger Bash script, which is in the same directory. You have the option to specify one or more parameters when running the script.
ProfileVisibilityChanger.py parameters
The following table describes the ProfileVisibilityChanger.py parameters:
| Parameter | Description |
|---|---|
-n | The fully qualified domain name of the machine where Portal for ArcGIS is installed (in other words, gisportal.domain.com). The default is the hostname of the machine where the script is run. |
-u | The username of an administrator account. |
-p | The password of an administrator account. |
-o | The directory where the profile visibility report will be saved. The default directory is the same folder where you run the script. |
-t | A token can be generated and used in place of the username and password. When generating a token, type userScan in the Webapp URL field. When a token is provided, it overrides any username or password that is provided. |
--ignoressl | Disable SSL certificate verification. If Python does not trust the issuer of the certificate used on port 7443, the script will fail to complete. If needed, this parameter can be specified to ignore all certificates. |
-a | The profile visibility, which can be set to one of the following:
|
--all | Include organization administrators. |
-h or -? | Outputs a listing of the parameters that can be specified when running the script. |
If the ProfileVisibilityChanger.py script is run without specifying parameters, you will be prompted to enter them manually or select the default value. If you want to use a token, it must be provided as a parameter when running the script.
When you generate a report, it will be saved in HTML format in the same folder where you run the script and is named user_categorized_report_<timestamp>.html. The report will list all members categorized by their profile visibility and allow you to filter the list.
Each time you run the ProfileVisibilityChanger.py script to change the profile visibility setting of members, a change report will be generated automatically. It will be saved in HTML format in the same folder where you run the script and is named user_changes_report_<timestamp>.html. The report will list all changes made to your members' profile visibility settings.
Example usage
To generate a categorized report, run the script as follows:./ProfileVisibilityChanger -n myportal.domain.com -u admin -p password
To set the profile visibility of all members, excluding administrators, to Public, run the script as follows:./ProfileVisibilityChanger -n myportal.domain.com -u admin -p password -a public
To set the profile visibility of all members, including administrators, to Organization, run the script as follows:./ProfileVisibilityChanger -n myportal.domain.com -u admin -p password -a org --all