<iframe src="https://www.googletagmanager.com/ns.html?id=GTM-M74D8PB" height="0" width="0" style="display:none;visibility:hidden">
Loading
Skip to NavigationSkip to Main Content
0D54z0000AA1lPpCQJOkta Identity EngineAccess GatewayAnswered2025-11-01T09:01:36.000Z2024-06-14T14:50:37.000Z2024-06-28T20:19:14.000Z

nhx3n (nhx3n) asked a question.

Okta Access Gateway - is it possible to set REMOTE_USER variable on server side?

I need to integrate an application that expects the UserId attribute to be filled in the REMOTE_USER variable. Is that possible?

also, how can I be sure that the cookies are properly set in OAG? They are not seen in the developer tools of the web browser once being redirected to the app.


  • Mihai N. (Okta, Inc.)

    Hi @nhx3n (nhx3n)​ , Thank you for reaching out to the Okta Community! 

     

    I ran this by my OAG colleagues and they confirmed that it's not possible to use REMOTE_USER variable as it's reserved by nginx. You will need to try changing the variable name.

    As for testing the cookies they referenced the following article that should help: 

    https://help.okta.com/oag/en-us/content/topics/access-gateway/task-configure-app-testing.htm

     

     

    If my answer helped, remember to mark it as best to increase its visibility for other members of the Okta Community who might have the same questions as you. 

     

    Hope my answer helps! 

     

    --

    Help others in the community by liking or hitting Select as Best if this response helped you.

    Expand Post
    Selected as Best
  • Mihai N. (Okta, Inc.)

    Hi @nhx3n (nhx3n)​ , Thank you for reaching out to the Okta Community! 

     

    I ran this by my OAG colleagues and they confirmed that it's not possible to use REMOTE_USER variable as it's reserved by nginx. You will need to try changing the variable name.

    As for testing the cookies they referenced the following article that should help: 

    https://help.okta.com/oag/en-us/content/topics/access-gateway/task-configure-app-testing.htm

     

     

    If my answer helped, remember to mark it as best to increase its visibility for other members of the Okta Community who might have the same questions as you. 

     

    Hope my answer helps! 

     

    --

    Help others in the community by liking or hitting Select as Best if this response helped you.

    Expand Post
    Selected as Best
  • nhx3n (nhx3n)

    Hi Mihai, many thanks for your reply. I'll try to figure out some other way to update the remote_user variable.

    I have another question now, How can I validate what attributes are actually being injected to the cookies? After landing in the application protected URL I cannot see any attributes in the browser cookies. Is that expected?

    thanks and regards.

    Expand Post
    • Mihai N. (Okta, Inc.)

      I've confirmed with my colleagues that the attributes, cookies etc set by OAG can’t be seen in browser console. 

      You should be able to validate it through the logs or by setting the protected URL to header.service.spgw as described in the link previously provided. 

       

      Regards.

      --

      Help others in the community by liking or hitting Select as Best if this response helped you.

      Expand Post
  • nhx3n (nhx3n)

    Mihai, thanks for your reply. Back to the first question, what could be the correct approach to define the value of a variable in the server side? via advanced policies? can you share an example of this? Thanks in advance.

    • Mihai N. (Okta, Inc.)

      Hi @nhx3n (nhx3n)​ .

      This would be outside of my area of expertise. Please open a case and my colleagues from the Support Team should be able to assist.

       

      Regards.

      --

      Help others in the community by liking or hitting Select as Best if this response helped you.

      Expand Post
This question is closed.
Loading
Okta Access Gateway - is it possible to set REMOTE_USER variable on server side?