[Progress Communities] [Progress OpenEdge ABL] Forum Post: RE: PAS SSO producer app not inserting CP properties

Status
Not open for further replies.
B

Blake Stanford

Guest
FWIW.....just in case it wasn't clear, any attributes that get added to the CP from the OERealm class as additional properties don't make it to the SSO token. Not just static properties from the securities.properties file. Roles assigned in the OERealm class do appear to make it to the SSO METHOD PUBLIC OVERRIDE CHARACTER GetAttribute ( INPUT piUserID AS INTEGER, INPUT pcAttrName AS CHARACTER ): DEFINE VARIABLE cValue AS CHARACTER NO-UNDO INITIAL ?. IF NOT THIS-OBJECT:validateRequest("GetAttribute") THEN MESSAGE "Unauthorized request". ELSE CASE pcAttrName: WHEN OERealmDefs:REALM_ATTR_ENABLED THEN ASSIGN cValue = STRING(isActive(piUserID), "1/0"). WHEN OERealmDefs:REALM_ATTR_LOCKED THEN ASSIGN cValue = STRING(isLocked(piUserID), "1/0"). WHEN OERealmDefs:REALM_ATTR_EXPIRED THEN ASSIGN cValue = STRING(isExpired(piUserID), "1/0"). WHEN OERealmDefs:REALM_ATTR_ROLES THEN ASSIGN cValue = getUserRoles(piUserID). WHEN OERealmDefs:REALM_ATTR_PROPERTIES THEN DO: cMyContextID = GUID (GENERATE-UUID). DEFINE VARIABLE jsonObj AS JSONObject. jsonObj = NEW JSONObject(). jsonObj:add("MyContextID",cMyContextID). jsonObj:Write(cValue, false). END. OTHERWISE ASSIGN cValue = ?. END CASE. RETURN cValue. end method. METHOD PUBLIC OVERRIDE CHARACTER getUserRoles ( INPUT piUserID AS INTEGER ): DEFINE VARIABLE lValidProdUser AS LOGICAL NO-UNDO. RETURN "MyUser". end method.

Continue reading...
 
Status
Not open for further replies.
Top