Search code examples
artifactory

How can I check the `Allow Anonymous Access` in Artifactory using an API call


I would like to be able to query this value for my artifactory to be able to test, in an automated way, whether anonymous access is enabled or not. Is there an endpoint that will provide this?

https://www.jfrog.com/confluence/display/JFROG/General+Security+Settings#GeneralSecuritySettings-AllowAnonymousAccess


Solution

  • An easy way can be using the Get General Configuration API:

    curl -uUSER:PASS $ARTIFACTORY-URL/artifactory/api/system/configuration -s | grep anonAccessEnabled