Web.Authenticate.OpenId

authenticate-1.3.3: Authentication methods for Haskell web applications.

Safe Haskell | None
Language | Haskell98

Web.Authenticate.OpenId

Contents

- Functions
- Types
  - Response

Synopsis

- getForwardUrl :: (MonadResource m, MonadBaseControl IO m) => Text -> Text -> Maybe Text -> [(Text, Text)] -> Manager -> m Text
- authenticate :: (MonadBaseControl IO m, MonadResource m, MonadIO m) => [(Text, Text)] -> Manager -> m (Identifier, [(Text, Text)])
- authenticateClaimed :: (MonadBaseControl IO m, MonadResource m, MonadIO m) => [(Text, Text)] -> Manager -> m OpenIdResponse
- data AuthenticateException
  - = RpxnowException String
  - | NormalizationException String
  - | DiscoveryException String
  - | AuthenticationException String
- newtype Identifier = Identifier {
  - identifier :: Text
  }
- data OpenIdResponse
- oirOpLocal :: OpenIdResponse -> Identifier
- oirParams :: OpenIdResponse -> [(Text, Text)]
- oirClaimed :: OpenIdResponse -> Maybe Identifier

# Functions

getForwardUrl

Arguments

:: (MonadResource m, MonadBaseControl IO m) |
=> Text | The openid the user provided.
-> Text | The URL for this application's complete page.
-> Maybe Text | Optional realm
-> [(Text, Text)] | Additional parameters to send to the OpenID provider. These can be useful for using extensions.
-> Manager |
-> m Text | URL to send the user to.

authenticate :: (MonadBaseControl IO m, MonadResource m, MonadIO m) => [(Text, Text)] -> Manager -> m (Identifier, [(Text, Text)])

Deprecated: Use authenticateClaimed

authenticateClaimed :: (MonadBaseControl IO m, MonadResource m, MonadIO m) => [(Text, Text)] -> Manager -> m OpenIdResponse

# Types

data AuthenticateException

Constructors

RpxnowException String |
NormalizationException String |
DiscoveryException String |
AuthenticationException String |

Instances

Show AuthenticateException |
Exception AuthenticateException |

newtype Identifier

A valid OpenID identifier.

Constructors

Identifier |
Fields identifier :: Text

Instances

Eq Identifier |
Data Identifier |
Ord Identifier |
Read Identifier |
Show Identifier |

## Response

data OpenIdResponse

oirOpLocal :: OpenIdResponse -> Identifier

oirParams :: OpenIdResponse -> [(Text, Text)]

oirClaimed :: OpenIdResponse -> Maybe Identifier