HsOpenSSL-0.11.7.9: Partial OpenSSL binding for Haskell

Safe Haskell | None
Language | Haskell2010

OpenSSL.EVP.Verify

Description

Message verification using asymmetric cipher and message digest algorithm. This is an opposite of OpenSSL.EVP.Sign.

Synopsis

- data VerifyStatus
  - = VerifySuccess
  - | VerifyFailure
- verify :: PublicKey key => Digest -> String -> key -> String -> IO VerifyStatus
- verifyBS :: PublicKey key => Digest -> ByteString -> key -> ByteString -> IO VerifyStatus
- verifyLBS :: PublicKey key => Digest -> ByteString -> key -> ByteString -> IO VerifyStatus

# Documentation

data VerifyStatus Source #

``VerifyStatus`` represents a result of verification.

Constructors

VerifySuccess |
VerifyFailure |

#### Instances

Instances details

Show VerifyStatus Source # |
Instance details Defined in OpenSSL.EVP.Verify Methods showsPrec :: Int -> VerifyStatus -> ShowS Source # show :: VerifyStatus -> String Source # showList :: [VerifyStatus] -> ShowS Source #
Eq VerifyStatus Source # |
Instance details Defined in OpenSSL.EVP.Verify Methods (==) :: VerifyStatus -> VerifyStatus -> Bool Source # (/=) :: VerifyStatus -> VerifyStatus -> Bool Source #

verify Source #

Arguments

:: PublicKey key |
=> Digest | message digest algorithm to use
-> String | message signature
-> key | public key to verify the signature
-> String | input string to verify
-> IO VerifyStatus | the result of verification

Deprecated: Use verifyBS or verifyLBS instead.

``verify`` verifies a signature and a stream of data. The string must not contain any letters which aren't in the range of U+0000 - U+00FF.

verifyBS Source #

Arguments

:: PublicKey key |
=> Digest | message digest algorithm to use
-> ByteString | message signature
-> key | public key to verify the signature
-> ByteString | input string to verify
-> IO VerifyStatus | the result of verification

``verifyBS`` verifies a signature and a chunk of data.

verifyLBS Source #

Arguments

:: PublicKey key |
=> Digest | message digest algorithm to use
-> ByteString | message signature
-> key | public key to verify the signature
-> ByteString | input string to verify
-> IO VerifyStatus | the result of verification

``verifyLBS`` verifies a signature of a stream of data.