When connecting to the SAS® Metadata Server, users might receive a "connecting as PUBLIC" error


When a user launches a SAS® client, they might receive one of the following errors:

Error
An unexpected error has occurred while accessing metadata.
You are not defined as a user in metadata and are connecting as PUBLIC. It appears that the current authorizations will not allow the connection to continue. Please contact your administrator.

  OR

The SAS Metadata Server rejected the connection attempt because the user name is not defined as a user in metadata. Please specify a different user or contact your administrator. 

  OR

The user "UserID" is not authorized to read metadata on server "Servername".

 

The problem occurs after the user ID has been authenticated on the server, when SAS is unable to find a matching metadata identity for the authenticated user ID.

When attempting to determine a SAS identity, the system attempts to match the authenticated user ID to the user ID stored in a metadata login. If no matching user ID is found, the connection is established using the PUBLIC identity. By default, PUBLIC and anonymous access are denied the ReadMetadata permission to the metadata repository.

Here are common conditions that result in error messages similar to the ones shown above and the basic resolution steps:

Determining How the User Is Authenticated

Enable TRACE logging for the Audit.Authentication logger on the SAS Metadata Server. This logger will show more detailed information about how the user is authenticated. 

Enabling TRACE logging for the loggers using SAS Management Console:

  1.  Log on to SAS Management Console as sasadm@saspw.
  2.  Expand Server Manager ► SASMeta ► SASMeta - Logical Metadata Server ► SASMeta - Metadata Server.
  3.  Right-click SASMeta - Metadata Server and select Connect.
  4.  Log on as sasadm@saspw if prompted.
  5.  Click the loggers tab.
  6.  Find Audit.Authentication in the list and select its properties.
  7.  Change the Assigned drop-down to TRACE.
  8.  Click OK.
  9.  Repeat steps 6-8 for the App.OMI.Security.GetInfo and App.OMI.Security.GetIdentity loggers.

Note: You will NOT need to restart the SAS Metadata Server for this change to take effect.

After you enable logging, have the affected user re-create the issue in the SAS client application. Then reset the Audit.Authentication logger to its original setting (typically this is "Inherited").

Opening the Metadata Server Log will show something similar to what is seen below for the user attempting to authenticate. Note that, in these examples, the domain "sasbi" was misspelled as "sassbi" in the User ID in the metadata. You should look for other differences between the User ID and the authenticated user, such as the domain name and direction of the slash if it is an Active Directory domain or a Windows local account. Also note that the form of the User ID can be either the UPN style or the Down-level name, sasdemo@sasbi or sasbi\sasdemo, respectively. Both are treated as the same User ID by the SAS Metadata Server.

- Create Authenticated Token
- Client connection id: 16
- User/Pass authentication for user sasdemo
- User: sasdemo, domain: sassbi​​​​​​ 
- Calling auth provider...
- Windows OS auth provider called
- Down-level name sasbi\sasdemo being authenticated
- Windows OS authentication successful
- New client connection (16) accepted from server port 8561 for user sasdemo@sasbi.

Additional logging from Step 9 might produce something like what is seen below in the Metadata Server log:

 TRACE [00000257] 6:sasdemo2@d10f562 - IOM RETURN 0={compRef:18909cac6c0}->OMI::GetInfo():
 output=[0..4,0..1]
  [0,0]=UserClass
  [0,1]=Normal
  [1,0]=AuthenticatedUserid
  [1,1]=SASDEMO2@SASSBI
  [2,0]=IdentityName
  [2,1]=PUBLIC
  [3,0]=IdentityType
  [3,1]=IdentityGroup
  [4,0]=IdentityObjectID
  [4,1]=A5BM63VV.A5000002

Related Information

For more information, see How SAS Identity Is Determined, PUBLIC Access and Anonymous Access, and Outbound and Trusted Authentication Domains in SAS® 9.4 Intelligence Platform: Security Administration Guide

Also see the section Add Users in SAS® 9.4 Management Console: Guide to Users and Permissions.