Copyright | (c) Greg Heartsfield 2007 |
---|---|
License | BSD3 |
Safe Haskell | None |
Language | Haskell98 |
Implements authentication and low-level communication with Amazon Web Services, such as S3, EC2, and others. API Version 2006-03-01 http://docs.amazonwebservices.com/AmazonS3/2006-03-01/
- runAction :: S3Action -> IO (AWSResult (HTTPResponse ByteString))
- isAmzHeader :: Header -> Bool
- preSignedURI :: S3Action -> Integer -> URI
- data S3Action = S3Action {
- s3conn :: AWSConnection
- s3bucket :: String
- s3object :: String
- s3query :: String
- s3metadata :: [(String, String)]
- s3body :: ByteString
- s3operation :: RequestMethod
- mimeEncodeQP :: String -> String
- mimeDecode :: String -> String
Function Types
runAction :: S3Action -> IO (AWSResult (HTTPResponse ByteString)) Source
Construct the request specified by an S3Action, send to Amazon, and return the response. Todo: add MD5 signature.
isAmzHeader :: Header -> Bool Source
Determine if a header belongs in the StringToSign
:: S3Action | Action with resource |
-> Integer | Expiration time, in seconds since 00:00:00 UTC on January 1, 1970 |
-> URI | URI of resource |
Construct a pre-signed URI, but don't act on it. This is useful for when an expiration date has been set, and the URI needs to be passed on to a client.
Data Types
An action to be performed using S3.
S3Action | |
|
Misc functions
mimeEncodeQP :: String -> String Source
mimeDecode :: String -> String Source
Decode a mime string, we know about quoted printable and base64 encoded UTF-8 S3 may convert quoted printable to base64