Forum Discussion
add username to URI after APM Logon
Hi everyone,
we are trying to change the URI and add an username as value to the query after APM Logon was succesful.
User connects to the APM Portal -> https://abc.com -> Login was sucessful -> https://abc.com/path/data?key=USERNAME
However, our iRule is not working. I think we have a mistake in our thinking..
when HTTP_REQUEST {
set user [ACCESS::session data get "session.logon.last.username"]
if { ([HTTP::path] equals "/") }{
HTTP::uri "/path/data?key=$user"
}
log local0. "User ist $user"
log local0. "[HTTP::uri]"
}
Thanks alot in advance!
Michael
2 Replies
- Michael_Jenkins
Cirrostratus
Are you talking about updating the URI as soon as the access policy completes and the user finishes login? If so, then it's important to note the event flow for APM. In that case
happens before all the APM related stuff.HTTP_REQUESTAre you setting a redirect page at the end of your policy? You could add the username there.
What does the log show as the URI after you try to change it?
- Moeter
Nimbostratus
Thanks alot!
Redirect was the solution.
https://1.1.1.1/path/data?key=%{session.logon.last.username}
:)
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
* 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
