You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When executing this project, if the angular app and the keycloak are on the same server, the example runs perfectly (local). When changing to a remote keycloak, after log in, the silent_refresh_error occurs.
The only difference is the issuer.
It works:
export const authConfig: AuthConfig = {
issuer: 'http://localhost:8080/auth/realms/myrealm',
clientId: 'spa-sigga-platform', // The "Auth Code + PKCE" client
responseType: 'code',
redirectUri: window.location.origin + '/index.html',
silentRefreshRedirectUri: window.location.origin + '/silent-refresh.html',
scope: 'openid profile email', // Ask offline_access to support refresh token refreshes
useSilentRefresh: true, // Needed for Code Flow to suggest using iframe-based refreshes
silentRefreshTimeout: 5000, // For faster testing
timeoutFactor: 0.25, // For faster testing
sessionChecksEnabled: true,
showDebugInformation: true, // Also requires enabling "Verbose" level in devtools
clearHashAfterLogin: false, // manfredsteyer/angular-oauth2-oidc#457 (comment),
requireHttps: false
};
It not works:
export const authConfig: AuthConfig = {
issuer: 'http://172.20.0.247:8080/auth/realms/myrealm',
clientId: 'spa-sigga-platform', // The "Auth Code + PKCE" client
responseType: 'code',
redirectUri: window.location.origin + '/index.html',
silentRefreshRedirectUri: window.location.origin + '/silent-refresh.html',
scope: 'openid profile email', // Ask offline_access to support refresh token refreshes
useSilentRefresh: true, // Needed for Code Flow to suggest using iframe-based refreshes
silentRefreshTimeout: 5000, // For faster testing
timeoutFactor: 0.25, // For faster testing
sessionChecksEnabled: true,
showDebugInformation: true, // Also requires enabling "Verbose" level in devtools
clearHashAfterLogin: false, // manfredsteyer/angular-oauth2-oidc#457 (comment),
//nonceStateSeparator : 'semicolon', // Real semicolon gets mangled by IdentityServer's URI encoding
requireHttps: false
};
Chrome console output:
The text was updated successfully, but these errors were encountered:
Hey! Sorry to hear you're having issues. However, this sounds like something quite specific to your setup and situation, and not so much an issue or bug with this sample repository? This sample is just a single-person project by me, so I don't really have time to support individual cases via this issues list. I recommend turning to a consultant, a forum, stack overflow, or similar. Hope you'll understand?
I believe my problem is related to another issue about Chrome not allowing cookies. I'm already following on another thread. Thanks for the feedback. Your samples helped me a lot!
Folks,
Did you face this problem?
When executing this project, if the angular app and the keycloak are on the same server, the example runs perfectly (local). When changing to a remote keycloak, after log in, the silent_refresh_error occurs.
The only difference is the issuer.
It works:
export const authConfig: AuthConfig = {
issuer: 'http://localhost:8080/auth/realms/myrealm',
clientId: 'spa-sigga-platform', // The "Auth Code + PKCE" client
responseType: 'code',
redirectUri: window.location.origin + '/index.html',
silentRefreshRedirectUri: window.location.origin + '/silent-refresh.html',
scope: 'openid profile email', // Ask offline_access to support refresh token refreshes
useSilentRefresh: true, // Needed for Code Flow to suggest using iframe-based refreshes
silentRefreshTimeout: 5000, // For faster testing
timeoutFactor: 0.25, // For faster testing
sessionChecksEnabled: true,
showDebugInformation: true, // Also requires enabling "Verbose" level in devtools
clearHashAfterLogin: false, // manfredsteyer/angular-oauth2-oidc#457 (comment),
requireHttps: false
};
It not works:
export const authConfig: AuthConfig = {
issuer: 'http://172.20.0.247:8080/auth/realms/myrealm',
clientId: 'spa-sigga-platform', // The "Auth Code + PKCE" client
responseType: 'code',
redirectUri: window.location.origin + '/index.html',
silentRefreshRedirectUri: window.location.origin + '/silent-refresh.html',
scope: 'openid profile email', // Ask offline_access to support refresh token refreshes
useSilentRefresh: true, // Needed for Code Flow to suggest using iframe-based refreshes
silentRefreshTimeout: 5000, // For faster testing
timeoutFactor: 0.25, // For faster testing
sessionChecksEnabled: true,
showDebugInformation: true, // Also requires enabling "Verbose" level in devtools
clearHashAfterLogin: false, // manfredsteyer/angular-oauth2-oidc#457 (comment),
//nonceStateSeparator : 'semicolon', // Real semicolon gets mangled by IdentityServer's URI encoding
requireHttps: false
};
Chrome console output:
The text was updated successfully, but these errors were encountered: