sassoftware / pyviyatools

Python command-line tools that call the SAS Viya REST APIs - for SAS administrators.
Apache License 2.0
38 stars 31 forks source link

Support for other authentication than .authinfo (eg. ./sas-viya auth loginCode) #155

Closed Juan4SAS closed 1 year ago

Juan4SAS commented 1 year ago

Hello,

I notice the login script support creating a token via standard .authinfo ( and sas-viya auth login). However, not all the Viya deployments have a pure LDAP connection. I would say that most work with a Single Sign-On procedure.

In these cases, .authinfo will not help.

Can the script currently support login via Authorization Codes (sas-viya auth loginCode)? And, if not, what is the current workaround to validate systems with SSO?

Thank you in advance! Best regards, Juan

gerrynelson63 commented 1 year ago

In this case, you would have to use sas-viya auth loginCode to authenticate. The tools do not provide a scripted way to do that.

However, recent changes to the sas-viya CLI and the default setting in Viya mean that you would only have to do the initial authentication every 90 days. You can see the details in this post. Please check out the section "SAS Viya CLI Auto-Refresh".