public class FSAccountManager extends Object
Modifier and Type | Method and Description |
---|---|
static FSAccountManager |
getInstance(String metaAlias)
Gets an Object for FSAccountManager Class.
|
String |
getUserID(FSAccountFedInfoKey fedInfoKey,
Map env)
Searches user with given combination of ProviderID & Opaque handle
in Default Organization.
|
String |
getUserID(FSAccountFedInfoKey fedInfoKey,
String orgDN,
Map env)
Searches user with given combination of ProviderID & Opaque handle
in given Organization.
|
String |
getUserID(Map avPair,
String orgDN,
Map env)
Gets the user by using a given search filter.
|
boolean |
hasAnyActiveFederation(String userID)
Returns true If Any Active federation is found where idpRole is true
means local deployment worked as SP in that federation and federation
is still Active.
|
boolean |
isFederationActive(String userID,
String providerID)
Returns true/false if Account's federation Status is Active / Inactive
for given providerID.
|
FSAccountFedInfo |
readAccountFedInfo(String userID,
String providerID)
Reads Account's federation Info from data store for given
providerID and returns value as fedInfo object.
|
FSAccountFedInfo |
readAccountFedInfo(String userID,
String providerID,
String nameIDValue)
Reads Account's federation Info from data store for given
providerID and returns value as fedInfo object.
|
Set |
readAllFederatedProviderID(String userID)
Reads All Account's federation Info from data store for given
user identity and returns a Set of ProviderIDs with which user
is federated (FedStatus is Active).
|
Set |
readAllFederatedProviderID(String providerID,
String userID)
Reads All Account's federation Info from data store for given
user identity and providerID.
|
void |
removeAccountFedInfo(String userID,
FSAccountFedInfo fedInfo)
Removes Account's federation Info in data store.
|
void |
removeAccountFedInfo(String userID,
FSAccountFedInfoKey fedInfoKey,
String providerID)
Removes Account's federation Info in data store for given providerID
in fedInfo object.
|
void |
removeAccountFedInfoKey(String userID,
FSAccountFedInfoKey fedInfoKey)
Removes Account's federation Info Key in data store.
|
void |
writeAccountFedInfo(String userID,
FSAccountFedInfoKey fedInfoKey,
FSAccountFedInfo fedInfo)
Stores Account's federation Info in data store.
|
void |
writeAccountFedInfo(String userID,
FSAccountFedInfoKey fedInfoKey,
FSAccountFedInfo fedInfo,
FSAccountFedInfoKey oldFedInfoKey)
Stores Account's federation Info in data store.
|
public static FSAccountManager getInstance(String metaAlias) throws FSAccountMgmtException
metaAlias
- meta alias of hosted providerFSAccountMgmtException
- if error occurred.public void writeAccountFedInfo(String userID, FSAccountFedInfoKey fedInfoKey, FSAccountFedInfo fedInfo) throws FSAccountMgmtException
userID
- user idfedInfo
- Account federation info as FSAccountFedInfo object.fedInfoKey
- Account Fed Info Key which contains NameSpace
and opaque handle sent/received.FSAccountMgmtException
- if illegal argument passed.public void removeAccountFedInfo(String userID, FSAccountFedInfo fedInfo) throws FSAccountMgmtException
userID
- user idfedInfo
- Account federation info as FSAccountFedInfo object.FSAccountMgmtException
- if illegal argument passed.
TODO, this may remove the wrong info key, as two
SP could federation with same IDP
use the one with providerID parameterpublic void writeAccountFedInfo(String userID, FSAccountFedInfoKey fedInfoKey, FSAccountFedInfo fedInfo, FSAccountFedInfoKey oldFedInfoKey) throws FSAccountMgmtException
userID
- user idfedInfo
- Account federation info as FSAccountFedInfo object.fedInfoKey
- Account Fed Info Key which contains NameSpace
& opaque handle sent/received.oldFedInfoKey
- Account Fed Info Key which contains NameSpace
& opaque handle sent/received, which will be removed.FSAccountMgmtException
- if illegal argument passed.public void removeAccountFedInfoKey(String userID, FSAccountFedInfoKey fedInfoKey) throws FSAccountMgmtException
userID
- user idfedInfoKey
- Account Fed Info Key which contains NameSpace
& opaque handle sent/received, which will be removed.FSAccountMgmtException
- if illegal argument passed.public void removeAccountFedInfo(String userID, FSAccountFedInfoKey fedInfoKey, String providerID) throws FSAccountMgmtException
userID
- user idfedInfoKey
- Account Fed Info Key which contains NameSpace
& opaque handle sent/received.providerID
- Remote ProviderID value.FSAccountMgmtException
- - If Account fed info is not found for
given user & given ProviderID.public FSAccountFedInfo readAccountFedInfo(String userID, String providerID) throws FSAccountMgmtException
userID
- user ID.providerID
- Remote ProviderID value.FSAccountMgmtException
- if an error occurred.public FSAccountFedInfo readAccountFedInfo(String userID, String providerID, String nameIDValue) throws FSAccountMgmtException
userID
- user ID.providerID
- Remote ProviderID value.nameIDValue
- fedinfo with this name ID value is to be found.FSAccountMgmtException
- if an error occurred.public Set readAllFederatedProviderID(String userID) throws FSAccountMgmtException
userID
- user identityFSAccountMgmtException
- if an error occurred.public Set readAllFederatedProviderID(String providerID, String userID) throws FSAccountMgmtException
userID
- user identityproviderID
- local provider IDFSAccountMgmtException
- if error occurred.public boolean isFederationActive(String userID, String providerID) throws FSAccountMgmtException
userID
- user identityproviderID
- Remote ProviderID value.FSAccountMgmtException
- - If Account fed info is not found for
given user & given ProviderID.public boolean hasAnyActiveFederation(String userID) throws FSAccountMgmtException
userID
- user idFSAccountMgmtException
- - If Account fed info is not found for
given user.public String getUserID(FSAccountFedInfoKey fedInfoKey, Map env) throws FSAccountMgmtException
fedInfoKey
- Account Fed Info Key which contains NameSpace
& opaque handle sent/received.env
- - Extra parameters that can be used for user mapping.FSAccountMgmtException
- - If Unable to get Organizationpublic String getUserID(FSAccountFedInfoKey fedInfoKey, String orgDN, Map env) throws FSAccountMgmtException
fedInfoKey
- Account Fed Info Key which contains NameSpace
& opaque handle sent/received.orgDN
- organization DN.env
- Extra parameters that can be used for user mapping.FSAccountMgmtException
- - If Unable to get Organization.public String getUserID(Map avPair, String orgDN, Map env) throws FSAccountMgmtException
avPair
- Attribute Value Pair to be used in finding the user.orgDN
- Organization DN.env
- Extra parameters that can be used for user mapping.FSAccountMgmtException
- if an error occurred.Copyright © 2010–2025 Open Identity Platform Community. All rights reserved.