PHP » PYTHON |
login |
register |
about
|
PYTHON openssl_sign
is this article helpful?
|
Python replacement for PHP's openssl_sign
[
edit
| history
]
sign(...)
Sign data with a digest @param pkey: Pkey to sign with @param data: data to be signed @param digest: message digest to use @return: signature import OpenSSL.crypto as ct ct.sign(prky, str, 'sha1') easy_install pyOpenSSL openssl_sign(PHP 4 >= 4.0.4, PHP 5) openssl_sign — Generate signature Description
bool openssl_sign
( string $data
, string &$signature
, mixed $priv_key_id
[, int $signature_alg= OPENSSL_ALGO_SHA1
] )
openssl_sign() computes a signature for the specified data by using SHA1 for hashing followed by encryption using the private key associated with priv_key_id . Note that the data itself is not encrypted. Parameters
Return ValuesReturns TRUE on success or FALSE on failure. Changelog
Examples
Example #1 openssl_sign() example
<?php
|
more
Recently updated
more
Most requested
more
Last requests
|