Handbook
Glossary
sign-params ( url request-method consumer-token request-token params -- oauth-params )
Vocabulary
oauth1
.
private
Inputs
url
an
object
request-method
an
object
consumer-token
an
object
request-token
an
object
params
an
object
Outputs
oauth-params
an
object
Definition
USING:
accessors
assocs
base64
checksums.hmac
checksums.sha
kernel
sequences
sorting
strings
;
IN:
oauth1.private
::
sign-params
( url request-method consumer-token request-token params -- oauth-params )
params
sort-keys
:>
params url request-method params
signature-base-string
:>
sbs consumer-token
secret>>
request-token
dup
[
secret>>
]
when
hmac-key
:>
key sbs key
sha1
hmac-bytes
>base64
>string
:>
signature params
{
"oauth_signature"
signature
}
prefix
[
"oauth_"
head?
]
filter-keys
;