--identities
FPM.ftd
.FPM.ftd
email
as identity.-- fpm.user-group: abrark-readers email: abrark.asahi@gmail.com
abrark-readers
in Sitemap with readers
key.-- fpm.sitemap: # Home: / readers: abrark-readers
fpm
BinaryFifthTry/fpm
and build it.cargo install --path=.
fpm
with CLI Parameter --identities
By setting --identities
as email: abrark.asahi@gmail.com
we are saying that at every http request this email
is the user identity and check the permission against this user identity.
Run fpm
with cli parameter --identities
in your package.
fpm serve --port 8000 --identities 'email: abrark.asahi@gmail.com'
/
in the browser, It will let access to /
page. If you will change email
identity in FPM.ftd
to other email and reload page again, so it will show unauthorized access.identities
FPM.ftd
email
as identity.-- fpm.user-group: abrark-readers email: abrark.asahi@gmail.com
abrark-readers
in Sitemap with readers
key.-- fpm.sitemap: # Home: / readers: abrark-readers
fpm
BinaryFifthTry/fpm
and build it.cargo install --path=.
fpm
fpm
binary in your package.fpm serve --port 8000
identities
Open browser window with /
and right click to open inspect
elements. Go to Application
and set cookies for http://127.0.0.1:8000
to identities
as email: abrark.asahi@gmail.com
. For more than one identities use comma separated values E.g. email: abrark.asahi@gmail.com, github: abrarnitk
.
Reload the window after setting the cookie, it will let access the document.
sid
CookieFPM.ftd
github-like
as identity.-- fpm.user-group: abrark-readers github-like: AbrarNitk/abrark
abrark-readers
in Sitemap with readers
key.-- fpm.sitemap: # Home: / readers: abrark-readers
Open link https://abrark.com/-/dj/login/github/
in browser and complete the OAuth login flow and provide permissions to FifthTry to access your GitHub APIs.
It will redirect to GitHub login page.
Click on Sign in
, and complete Two-factor if any.
It will redirect to authorize page.
Click on Authorize FifthTry
, after that you will be redirected to abrark.com
.
Check GET API https://abrark.com/-/dj/get-identities/
, It will give below response.
{ "success": true, "user-identities": [{"github": "AbrarNitk"}] }
Now copy sid
cookie from https://abrark.com/
and paste it in http://127.0.0.1:8000
cookie with sid
key.
Note: Go to fpm::controller::get_remote_identities
and change remote_host
in fpm
, to abrark.com
.
fpm
with Remote Featurecargo install --path=. --features remote
fpm
fpm
binary in your package.fpm serve --port 8000
Now go to AbrarNitk/abrark repository and give a star, you should be able access /
document. If you undo star and access it again it will give unauthorized access.
Yay!!! Such a magic it is. 💫