If you are not familiar with Pure Safemode, you should be, check out the details here:
Or some of my thoughts in general here
Each FlashArray, Cloud Block Store, and FlashBlade has a built-in REST API, but so does Pure1–a place that aggregates all reporting for you in one API. Reporting on a Safemode configuration is a useful tool, to ensure our extra protections are configured (if they aren’t reach out to Pure support–for security reasons customers cannot turn it on themselves, nor off).
The Pure1 REST API has a beta release out (v1.1.b) that includes Safemode reporting in the arrays endpoint and it is super easy to pull via PowerShell.
Install the module (if you haven’t):
Install-Module PureStorage.Pure1
Create a new certificate (if you haven’t already) and retrieve the public key
Login to Pure1.purestorage.com as an admin and add the public key to Pure1 and get the application ID.
If you already created an app ID you do not need to do all of the above each time. Just once.
Now normally you can just connect, but the module auto-connects to the latest GA REST version by default, so before you do you need to set a variable to force it to the beta release:
Now connect.
Next, use Get-PureOneArrays and store it in a variable.
If you look at one of the results, you will see each array returned has a new property:
safe_mode
And there are additional properties available stating what is turned on (if at all)
If you see all-disabled, it means it is not enabled on that platform. Now keep in mind, this is a beta API so it may and likely will change by GA release of the REST–especially since our Safemode work is rapidly expanding on the storage platforms.