Method | Description | |
---|---|---|
DecodeAndValidateToken ( string token ) : string |
Decodes and validates the raw token.
|
|
DecodeAndValidateToken ( string token, byte cryptKey, byte signKey ) : string |
Decodes and validates the raw token with appropriate crypt key and sign key.
|
|
DecodeToken ( string token ) : string |
Decode the given token. Returns null on failure.
|
|
DecodeToken ( string token, byte cryptKey ) : string |
Decode the given token. Returns null on failure.
|
|
GetAppLoginUrl ( ) : string |
Returns the URL needed to retrieve the application security token. The application security token will be generated for the Windows Live site. JavaScript Output Notation (JSON) output is returned: {"token":"<value>"}
|
|
GetAppLoginUrl ( string siteId ) : string |
Returns the URL needed to retrieve the application security token. By default, the application security token will be generated for the Windows Live site; a specific Site ID can optionally be specified in 'siteId'. JSON output is returned: {"token":"<value>"}
|
|
GetAppLoginUrl ( string siteId, string ip ) : string |
Returns the URL needed to retrieve the application security token. By default, the application security token will be generated for the Windows Live site; a specific Site ID can optionally be specified in 'siteId'. The IP address can also optionally be included in 'ip'. JSON output is returned: {"token":"<value>"}
|
|
GetAppLoginUrl ( string siteId, string ip, bool js ) : string |
Returns the URL needed to retrieve the application security token. By default, the application security token will be generated for the Windows Live site; a specific Site ID can optionally be specified in 'siteId'. The IP address can also optionally be included in 'ip'. If 'js' is false, then JSON output is returned: {"token":"<value>"} Otherwise, a JavaScript response is returned. It is assumed that WLIDResultCallback is a custom function implemented to handle the token value: WLIDResultCallback("<tokenvalue>");
|
|
GetAppRetCode ( ) : string |
Returns a string that can be passed to the GetTrustedParams function as the 'retcode' parameter. If this is specified as the 'retcode', then the app will be used as return URL after it finishes trusted sign-in.
|
|
GetAppSecurityToken ( ) : string |
Retrieves the application security token for application verification from the application sign-in URL. The application security token will be generated for the Windows Live site.
|
|
GetAppSecurityToken ( string siteId ) : string |
Retrieves the application security token for application verification from the application sign-in URL. By default, the application security token will be generated for the Windows Live site; a specific Site ID can optionally be specified in 'siteId'.
|
|
GetAppSecurityToken ( string siteId, string ip ) : string |
Retrieves the application security token for application verification from the application sign-in URL. By default, the application security token will be generated for the Windows Live site; a specific Site ID can optionally be specified in 'siteId'. The IP address can also optionally be included in 'ip'. Implementation note: The application security token is downloaded from the application sign-in URL in JSON format {"token":"<value>"}, so we need to extract <value> from the string and return it as seen here.
|
|
GetAppVerifier ( ) : string |
Generates an Application Verifier token.
|
|
GetAppVerifier ( string ip ) : string |
Generates an Application Verifier token. An IP address can be included in the token.
|
|
GetClearCookieResponse ( string &type, byte &content ) : void |
Returns an appropriate content type and body response that the application handler can return to signify a successful sign-out from the application. When a user signs out of Windows Live or a Windows Live application, a best-effort attempt is made to sign the user out from all other Windows Live applications the user might be signed in to. This is done by calling the handler page for each application with 'action' parameter set to 'clearcookie' in the query string. The application handler is then responsible for clearing any cookies or data associated with the sign-in. After successfully signing the user out, the handler should return a GIF (any GIF) as response to the action=clearcookie query.
|
|
GetConsentUrl ( string offers ) : string |
Returns the consent URL to use for Delegated Authentication for the given comma-delimited list of offers.
|
|
GetConsentUrl ( string offers, string context ) : string |
Returns the consent URL to use for Delegated Authentication for the given comma-delimited list of offers.
|
|
GetConsentUrl ( string offers, string context, string ru ) : string |
Returns the consent URL to use for Delegated Authentication for the given comma-delimited list of offers.
|
|
GetConsentUrl ( string offers, string context, string ru, string market ) : string |
Returns the consent URL to use for Delegated Authentication for the given comma-delimited list of offers.
|
|
GetLoginUrl ( ) : string |
Returns the sign-in URL to use for the Windows Live Login server. We recommend that you use the Sign In control instead.
|
|
GetLoginUrl ( string context ) : string |
Returns the sign-in URL to use for the Windows Live Login server. We recommend that you use the Sign In control instead.
|
|
GetLoginUrl ( string context, string market ) : string |
Returns the sign-in URL to use for the Windows Live Login server. We recommend that you use the Sign In control instead.
|
|
GetLogoutUrl ( ) : string |
Returns the sign-out URL to use for the Windows Live Login server. We recommend that you use the Sign In control instead.
|
|
GetLogoutUrl ( string market ) : string |
Returns the sign-out URL to use for the Windows Live Login server. We recommend that you use the Sign In control instead.
|
|
GetManageConsentUrl ( ) : string |
Returns the URL for the consent-management user interface.
|
|
GetManageConsentUrl ( string market ) : string |
Returns the URL for the consent-management user interface.
|
|
GetRefreshConsentTokenUrl ( string offers, string refreshToken ) : string |
Returns the URL to use to download a new consent token, given the offers and refresh token.
|
|
GetRefreshConsentTokenUrl ( string offers, string refreshToken, string ru ) : string |
Returns the URL to use to download a new consent token, given the offers and refresh token.
|
|
GetTrustedLoginUrl ( ) : string |
Returns the trusted sign-in URL to use for the Windows Live Login server.
|
|
GetTrustedLogoutUrl ( ) : string |
Returns the trusted sign-out URL to use for the Windows Live Login server.
|
|
GetTrustedParams ( string user ) : |
Returns a table of key-value pairs that must be posted to the sign-in URL for trusted sign-in. Use HTTP POST to do this. Be aware that the values in the table are neither URL nor HTML escaped and may have to be escaped if you are inserting them in code such as an HTML form. The user to be trusted on the local site is passed in as string 'user'.
|
|
GetTrustedParams ( string user, string retcode ) : |
Returns a table of key-value pairs that must be posted to the sign-in URL for trusted sign-in. Use HTTP POST to do this. Be aware that the values in the table are neither URL nor HTML escaped and may have to be escaped if you are inserting them in code such as an HTML form. The user to be trusted on the local site is passed in as string 'user'. Optionally, 'retcode' specifies the resource to which successful sign-in is redirected, such as Windows Live Mail, and is typically a string in the format 'id=2000'. If you pass in the value from GetAppRetCode instead, sign-in will be redirected to the application. Otherwise, an HTTP 200 response is returned.
|
|
GetTrustedToken ( string user ) : string |
Returns the trusted sign-in token in the format needed by the trusted sign-in gadget. User to be trusted on the local site is passed in as string 'user'.
|
|
ProcessConsent ( |
Processes the POST response from the Delegated Authentication service after a user has granted consent. The processConsent function extracts the consent token string and returns the result of invoking the processConsentToken method.
|
|
ProcessConsentToken ( string token ) : ConsentToken |
Processes the consent token string that is returned in the POST response by the Delegated Authentication service after a user has granted consent.
|
|
ProcessConsentToken ( string token, string context ) : ConsentToken |
Processes the consent token string that is returned in the POST response by the Delegated Authentication service after a user has granted consent.
|
|
ProcessLogin ( |
Processes the sign-in response from the Windows Live Login server.
|
|
ProcessToken ( string token ) : User |
Decodes and validates a Web Authentication token. Returns a User object on success.
|
|
ProcessToken ( string token, string context ) : User |
Decodes and validates a Web Authentication token. Returns a User object on success. If a context is passed in, it will be returned as the context field in the User object.
|
|
RefreshConsentToken ( ConsentToken token ) : ConsentToken |
Attempts to obtain a new, refreshed token and return it. The original token is not modified.
|
|
RefreshConsentToken ( ConsentToken token, string ru ) : ConsentToken |
Attempts to obtain a new, refreshed token and return it. The original token is not modified.
|
|
RefreshConsentToken ( string offers, string refreshToken ) : ConsentToken |
Attempts to obtain a new, refreshed token and return it using the offers and refresh token. The original token is not modified.
|
|
RefreshConsentToken ( string offers, string refreshToken, string ru ) : ConsentToken |
Attempts to obtain a new, refreshed token and return it using the offers and refresh token. The original token is not modified.
|
|
SignToken ( string token ) : byte[] |
Creates a signature for the given string.
|
|
SignToken ( string token, byte signKey ) : byte[] |
Creates a signature for the given string by using the signature key.
|
|
ValidateToken ( string token ) : string |
Extracts the signature from the token and validates it.
|
|
ValidateToken ( string token, byte signKey ) : string |
Extracts the signature from the token and validates it by using the signature key.
|
|
WindowsLiveLogin ( bool loadAppSettings ) : System |
Initialize the WindowsLiveLogin module from the web.config file if loadAppSettings is true. Otherwise, you will have to manually set the AppId, Secret and SecurityAlgorithm properties. In a Delegated Authentication scenario, you may also specify the return and privacy policy URLs to use, as shown in the Delegated Authentication samples.
|
|
WindowsLiveLogin ( bool forceDelAuthNonProvisioned, string policyUrl, string returnUrl ) : System |
Initialize the WindowsLiveLogin module with the forceDelAuthNonProvisioned flag, policy URL, and return URL. The 'force_delauth_nonprovisioned' flag indicates whether your application is registered for Delegated Authentication (that is, whether it uses an application ID and secret key). We recommend that your Delegated Authentication application always be registered for enhanced security and functionality.
|
|
WindowsLiveLogin ( string settingsFile ) : System |
|
|
WindowsLiveLogin ( string appId, string secret ) : System |
Initialize the WindowsLiveLogin module with the application ID and secret key. We recommend that you employ strong measures to protect the secret key. The secret key should never be exposed to the Web or other users.
|
|
WindowsLiveLogin ( string appId, string secret, string securityAlgorithm ) : System |
Initialize the WindowsLiveLogin module with the application ID, secret key, and security algorithm. We recommend that you employ strong measures to protect the secret key. The secret key should never be exposed to the Web or other users.
|
|
WindowsLiveLogin ( string appId, string secret, string securityAlgorithm, bool forceDelAuthNonProvisioned ) : System |
Initialize the WindowsLiveLogin module with the application ID, secret key, security algorithm and forceDelAuthNonProvisioned flag. We recommend that you employ strong measures to protect the secret key. The secret key should never be exposed to the Web or other users. The 'force_delauth_nonprovisioned' flag indicates whether your application is registered for Delegated Authentication (that is, whether it uses an application ID and secret key). We recommend that your Delegated Authentication application always be registered for enhanced security and functionality.
|
|
WindowsLiveLogin ( string appId, string secret, string securityAlgorithm, bool forceDelAuthNonProvisioned, string policyUrl ) : System |
Initialize the WindowsLiveLogin module with the application ID, secret key, security algorithm, forceDelAuthNonProvisioned and policy URL use. We recommend that you employ strong measures to protect the secret key. The secret key should never be exposed to the Web or other users. The 'force_delauth_nonprovisioned' flag indicates whether your application is registered for Delegated Authentication (that is, whether it uses an application ID and secret key). We recommend that your Delegated Authentication application always be registered for enhanced security and functionality.
|
|
WindowsLiveLogin ( string appId, string secret, string securityAlgorithm, bool forceDelAuthNonProvisioned, string policyUrl, string returnUrl ) : System |
Method | Description | |
---|---|---|
debug ( string msg ) : void |
Stub implementation for logging debug output. You can run a tool such as 'dbmon' to see the output.
|
|
derive ( string secret, string prefix ) : byte[] |
Derives the key, given the secret key and prefix as described in the Web Authentication SDK documentation.
|
|
e64 ( byte b ) : string |
Base64-encodes and URL-escapes a byte array.
|
|
fetch ( string url ) : string |
Fetches the contents given a URL.
|
|
getTimestamp ( ) : string |
Generates a timestamp suitable for the application verifier token.
|
|
parse ( string input ) : |
Parses query string and return a table representation of the key and value pairs. Similar to HttpUtility.ParseQueryString, except that no URL decoding is done and only the last value is considered in the case of multiple values with one key.
|
|
parseSettings ( string settingsFile ) : |
Function to parse the settings file.
|
|
u64 ( string s ) : byte[] |
URL-unescapes and Base64-decodes a string.
|
public DecodeAndValidateToken ( string token ) : string | ||
token | string | |
return | string |
public DecodeAndValidateToken ( string token, byte cryptKey, byte signKey ) : string | ||
token | string | Raw token. |
cryptKey | byte | Crypt key. |
signKey | byte | Sign key. |
return | string |
public DecodeToken ( string token ) : string | ||
token | string | Raw token. |
return | string |
public DecodeToken ( string token, byte cryptKey ) : string | ||
token | string | Raw token. |
cryptKey | byte | Crypt key. |
return | string |
public GetAppLoginUrl ( string siteId ) : string | ||
siteId | string | |
return | string |
public GetAppLoginUrl ( string siteId, string ip ) : string | ||
siteId | string | |
ip | string | |
return | string |
public GetAppLoginUrl ( string siteId, string ip, bool js ) : string | ||
siteId | string | |
ip | string | |
js | bool | |
return | string |
public GetAppSecurityToken ( string siteId ) : string | ||
siteId | string | |
return | string |
public GetAppSecurityToken ( string siteId, string ip ) : string | ||
siteId | string | |
ip | string | |
return | string |
public GetClearCookieResponse ( string &type, byte &content ) : void | ||
type | string | |
content | byte | |
return | void |
public GetConsentUrl ( string offers ) : string | ||
offers | string | Comma-delimited list of offers. |
return | string |
public GetConsentUrl ( string offers, string context ) : string | ||
offers | string | Comma-delimited list of offers. |
context | string | If you specify it, |
return | string |
public GetConsentUrl ( string offers, string context, string ru ) : string | ||
offers | string | Comma-delimited list of offers. |
context | string | If you specify it, |
ru | string | The registered/configured return URL will be /// overridden by 'ru' specified here. |
return | string |
public GetConsentUrl ( string offers, string context, string ru, string market ) : string | ||
offers | string | Comma-delimited list of offers. |
context | string | If you specify it, |
ru | string | The registered/configured return URL will be /// overridden by 'ru' specified here. |
market | string | The language in which the consent page is /// displayed is configured by culture ID (For example, 'fr-fr' or /// 'en-us') specified in the 'market' parameter. |
return | string |
public GetLoginUrl ( string context ) : string | ||
context | string | If you specify it, |
return | string |
public GetLoginUrl ( string context, string market ) : string | ||
context | string | If you specify it, |
market | string | The language in which the sign-in page is /// displayed is configured by culture ID (For example, 'fr-fr' or /// 'en-us') specified in the 'market' parameter. |
return | string |
public GetLogoutUrl ( string market ) : string | ||
market | string | The language in which the sign-in page is /// displayed is configured by culture ID (For example, 'fr-fr' or /// 'en-us') specified in the 'market' parameter. |
return | string |
public GetManageConsentUrl ( string market ) : string | ||
market | string | The language in which the consent page is /// displayed is configured by culture ID (For example, 'fr-fr' or /// 'en-us') specified in the 'market' parameter. |
return | string |
public GetRefreshConsentTokenUrl ( string offers, string refreshToken ) : string | ||
offers | string | Comma-delimited list of offers. |
refreshToken | string | Refresh token. |
return | string |
public GetRefreshConsentTokenUrl ( string offers, string refreshToken, string ru ) : string | ||
offers | string | Comma-delimited list of offers. |
refreshToken | string | Refresh token. |
ru | string | The registered/configured return URL will be /// overridden by 'ru' specified here. |
return | string |
public GetTrustedParams ( string user ) : |
||
user | string | |
return |
public GetTrustedParams ( string user, string retcode ) : |
||
user | string | |
retcode | string | |
return |
public GetTrustedToken ( string user ) : string | ||
user | string | |
return | string |
public ProcessConsent ( |
||
query | Response from the Delegated Authentication service. | |
return | ConsentToken |
public ProcessConsentToken ( string token ) : ConsentToken | ||
token | string | Raw token. |
return | ConsentToken |
public ProcessConsentToken ( string token, string context ) : ConsentToken | ||
token | string | Raw token. |
context | string | If you specify it, |
return | ConsentToken |
public ProcessLogin ( |
||
query | Contains the preprocessed POST query /// such as that returned by HttpRequest.Form | |
return | User |
public ProcessToken ( string token, string context ) : User | ||
token | string | Web Authentication token |
context | string | If you specify it, |
return | User |
public RefreshConsentToken ( ConsentToken token ) : ConsentToken | ||
token | ConsentToken | ConsentToken object. |
return | ConsentToken |
public RefreshConsentToken ( ConsentToken token, string ru ) : ConsentToken | ||
token | ConsentToken | ConsentToken object. |
ru | string | The registered/configured return URL will be /// overridden by 'ru' specified here. |
return | ConsentToken |
public RefreshConsentToken ( string offers, string refreshToken ) : ConsentToken | ||
offers | string | Comma-delimited list of offers. |
refreshToken | string | Refresh token. |
return | ConsentToken |
public RefreshConsentToken ( string offers, string refreshToken, string ru ) : ConsentToken | ||
offers | string | Comma-delimited list of offers. |
refreshToken | string | Refresh token. |
ru | string | The registered/configured return URL will be /// overridden by 'ru' specified here. |
return | ConsentToken |
public SignToken ( string token, byte signKey ) : byte[] | ||
token | string | |
signKey | byte | |
return | byte[] |
public ValidateToken ( string token ) : string | ||
token | string | |
return | string |
public ValidateToken ( string token, byte signKey ) : string | ||
token | string | |
signKey | byte | |
return | string |
public WindowsLiveLogin ( bool loadAppSettings ) : System | ||
loadAppSettings | bool | |
return | System |
public WindowsLiveLogin ( bool forceDelAuthNonProvisioned, string policyUrl, string returnUrl ) : System | ||
forceDelAuthNonProvisioned | bool | |
policyUrl | string | |
returnUrl | string | |
return | System |
public WindowsLiveLogin ( string settingsFile ) : System | ||
settingsFile | string | |
return | System |
public WindowsLiveLogin ( string appId, string secret ) : System | ||
appId | string | |
secret | string | |
return | System |
public WindowsLiveLogin ( string appId, string secret, string securityAlgorithm ) : System | ||
appId | string | |
secret | string | |
securityAlgorithm | string | |
return | System |
public WindowsLiveLogin ( string appId, string secret, string securityAlgorithm, bool forceDelAuthNonProvisioned ) : System | ||
appId | string | |
secret | string | |
securityAlgorithm | string | |
forceDelAuthNonProvisioned | bool | |
return | System |
public WindowsLiveLogin ( string appId, string secret, string securityAlgorithm, bool forceDelAuthNonProvisioned, string policyUrl ) : System | ||
appId | string | |
secret | string | |
securityAlgorithm | string | |
forceDelAuthNonProvisioned | bool | |
policyUrl | string | |
return | System |
public WindowsLiveLogin ( string appId, string secret, string securityAlgorithm, bool forceDelAuthNonProvisioned, string policyUrl, string returnUrl ) : System | ||
appId | string | |
secret | string | |
securityAlgorithm | string | |
forceDelAuthNonProvisioned | bool | |
policyUrl | string | |
returnUrl | string | |
return | System |