Getting a refresh token when trying to generate an offline token using JavaScript code

Solution Unverified - Updated -

Issue

  • I'm getting a refresh token (instead of an expected offline token) when trying to generate the offline token using the below JS code:

    JS code:
            keycloak.login({'scope': 'offline_access'}).success(function(authenticated) {
            }).error(function() {
                alert('Init Error');
            });
    
  • Any idea on how to get offline token (and not the refresh one) ?

Environment

  • Red Hat Single Sign-On (RH-SSO)
    • 7

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In