mirror of
https://github.com/urbit/shrub.git
synced 2024-12-04 04:35:02 +03:00
stub security driver: check that authorization exists
This commit is contained in:
parent
be51072ade
commit
faf017da53
23
sec/com/twitter.hoon
Normal file
23
sec/com/twitter.hoon
Normal file
@ -0,0 +1,23 @@
|
||||
:: Test url +https://slack.com/api/auth.test
|
||||
::
|
||||
:::: /hoon/slack/com/sec
|
||||
::
|
||||
/+ oauth1
|
||||
::
|
||||
::::
|
||||
::
|
||||
::=+ ^= aut
|
||||
:: %+ oauth2
|
||||
:: 'https://slack.com/oauth/authorize'
|
||||
:: 'https://slack.com/api/oauth.access'
|
||||
|_ {(bale @t:keys:oauth1) tok/{@t @t}}
|
||||
::++ aut ~(. ^aut +<- /client/admin)
|
||||
::++ out (out-quay:aut 'token'^tok)
|
||||
:: ++ in in-code:aut
|
||||
:: ++ bak (bak-save-access:aut . |=(tok/token:aut +>(tok tok)))
|
||||
++ out
|
||||
|= a/hiss ^- {$send hiss}
|
||||
~| %authorization
|
||||
~& twit-auth+(~(got by q.q.a) %authorization)
|
||||
[%send a]
|
||||
--
|
Loading…
Reference in New Issue
Block a user