Forum Discussion
Khalid_A
Nimbostratus
Mar 05, 2018Creating JWS session tables
Hi,
We're implementing API authentication/authorization based on JWT.
The API and authorization server are all behind F5.
We've been asked just to store the JWS sent back from the authorization ...
JRahm
Admin
Mar 06, 2018Yep, that's clear. Totally doable with an iRule, and you can store the data in the session table via the table command with the external token being the key and the internal token being the value. Pseudo code would be something like:
when HTTP_RESPONSE {
set key
table set $key $internal_token $expiration_in_seconds
}
when HTTP_REQUEST {
set int_key [table lookup $ext_key]
if { $int_key ne "" } {
HTTP::header replace header int_key
}
else { HTTP::header remove header }
}Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects