Skip to content

Commit

Permalink
Adding amazon_s34_sign().
Browse files Browse the repository at this point in the history
See: #440
  • Loading branch information
jaswsinc committed Jan 8, 2015
1 parent 19d917e commit e56e2cf
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions s2member/includes/classes/files-in.inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -654,20 +654,20 @@ public static function amazon_s3_sign($string = '')
}

/**
* Creates an Amazon S3 HMAC-SHA1 signature.
* Creates an Amazon S3 HMAC-SHA256 signature.
*
* @package s2Member\Files
* @since 110524RC
*
* @param string $string Input string/data, to be signed by this routine.
*
* @return string An HMAC-SHA1 signature for Amazon S3.
* @return string An HMAC-SHA256 signature for Amazon S3.
*/
public static function amazon_s34_sign($string = '')
{
$s3c['secret_key'] = $GLOBALS['WS_PLUGIN__']['s2member']['o']['amazon_s3_files_secret_key'];

return c_ws_plugin__s2member_utils_strings::hmac_sha1_sign((string)$string, $s3c['secret_key']);
return c_ws_plugin__s2member_utils_strings::hmac_sha256_sign((string)$string, $s3c['secret_key']);
}

/**
Expand Down

0 comments on commit e56e2cf

Please sign in to comment.