Function get_auth_header - echiong/testRepo GitHub Wiki

Creates the authorization portion of a header NOTE: This does not create a complete http header. Also NOTE: the oauth_token parameter should be passed in using the $extra array.

Located at application/helpers/oauth_helper.php

Return value summary

Type: string

Description: the header authorization portion with trailing \r\n

Parameters summary

string $baseurl the base url we are authenticating against. $baseurl

the base url we are authenticating against.

2. ` string $key your consumer key ` ` $key `

your consumer key

3. ` string $secret either your consumer secret key or the file location of your rsa private key. ` ` $secret `

either your consumer secret key or the file location of your rsa private key.

4. ` array $extra additional oauth parameters that should be included (you must urlencode a parameter, if appropriate, before calling this function) ` ` $extra = array() `

additional oauth parameters that should be included (you must urlencode a parameter, if appropriate, before calling this function)

5. ` string $method either GET or POST ` ` $method = 'GET' `

either GET or POST

6. ` string $algo either HMAC-SHA1 or RSA-SHA1 (NOTE: this affects what you put in for the secret parameter) ` ` $algo = OAUTH_ALGORITHMS::RSA_SHA1 `

either HMAC-SHA1 or RSA-SHA1 (NOTE: this affects what you put in for the secret parameter)

⚠️ **GitHub.com Fallback** ⚠️