Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

After Login goes here and error #2

Open
ghost opened this issue Oct 21, 2019 · 4 comments
Open

After Login goes here and error #2

ghost opened this issue Oct 21, 2019 · 4 comments
Labels
question Further information is requested

Comments

@ghost
Copy link

ghost commented Oct 21, 2019

http://consumer.ankuranand.in:3020/?ssoToken=GN33Vv3O9rC3NXDJQWYLiR6BRM4
{"message":"Internal Server Error"}

@hamny88
Copy link

hamny88 commented May 14, 2020

Me either... same problem..

@ankur-anand ankur-anand added the question Further information is requested label Aug 30, 2020
@ankur-anand
Copy link
Owner

Kindly provide the complete error log that is coming in the console.

@kazhuyo
Copy link

kazhuyo commented Nov 11, 2020

me too, here's the log from console :

GET / 302 8.315 ms - 210
{
  message: 'Request failed with status code 403',
  error: Error: Request failed with status code 403
      at createError (/Users/zhen/Documents/Development/sample-sso/sso-consumer-2/node_modules/axios/lib/core/createError.js:16:15)
      at settle (/Users/zhen/Documents/Development/sample-sso/sso-consumer-2/node_modules/axios/lib/core/settle.js:18:12)
      at IncomingMessage.handleStreamEnd (/Users/zhen/Documents/Development/sample-sso/sso-consumer-2/node_modules/axios/lib/adapters/http.js:202:11)
      at IncomingMessage.emit (events.js:326:22)
      at endReadableNT (_stream_readable.js:1223:12)
      at processTicksAndRejections (internal/process/task_queues.js:84:21) {
    config: {
      adapter: [Function: httpAdapter],
      transformRequest: [Object],
      transformResponse: [Object],
      timeout: 0,
      xsrfCookieName: 'XSRF-TOKEN',
      xsrfHeaderName: 'X-XSRF-TOKEN',
      maxContentLength: -1,
      validateStatus: [Function: validateStatus],
      headers: [Object],
      method: 'get',
      url: 'http://auth.portal.com:3010/simplesso/verifytoken?ssoToken=KVwwklY6olH7r494XVymtxEolE7',
      data: undefined
    },
    request: ClientRequest {
      _events: [Object: null prototype],
      _eventsCount: 6,
      _maxListeners: undefined,
      outputData: [],
      outputSize: 0,
      writable: true,
      _last: true,
      chunkedEncoding: false,
      shouldKeepAlive: false,
      useChunkedEncodingByDefault: false,
      sendDate: false,
      _removedConnection: false,
      _removedContLen: false,
      _removedTE: false,
      _contentLength: 0,
      _hasBody: true,
      _trailer: '',
      finished: true,
      _headerSent: true,
      socket: [Socket],
      connection: [Socket],
      _header: 'GET /simplesso/verifytoken?ssoToken=KVwwklY6olH7r494XVymtxEolE7 HTTP/1.1\r\n' +
        'Accept: application/json, text/plain, */*\r\n' +
        'Authorization: Bearer l1Q7zkOL59cRqWBkQ12ZiGVW2DBL\r\n' +
        'User-Agent: axios/0.18.1\r\n' +
        'Host: auth.portal.com:3010\r\n' +
        'Connection: close\r\n' +
        '\r\n',
      _keepAliveTimeout: 0,
      _onPendingData: [Function: noopPendingOutput],
      agent: [Agent],
      socketPath: undefined,
      method: 'GET',
      insecureHTTPParser: undefined,
      path: '/simplesso/verifytoken?ssoToken=KVwwklY6olH7r494XVymtxEolE7',
      _ended: true,
      res: [IncomingMessage],
      aborted: false,
      timeoutCb: null,
      upgradeOrConnect: false,
      parser: null,
      maxHeadersCount: null,
      reusedSocket: false,
      host: 'auth.portal.com',
      protocol: 'http:',
      _redirectable: [Writable],
      [Symbol(kCapture)]: false,
      [Symbol(kNeedDrain)]: false,
      [Symbol(corked)]: 0,
      [Symbol(kOutHeaders)]: [Object: null prototype]
    },
    response: {
      status: 403,
      statusText: 'Forbidden',
      headers: [Object],
      config: [Object],
      request: [ClientRequest],
      data: [Object]
    }
  }
}
GET /?ssoToken=KVwwklY6olH7r494XVymtxEolE7 500 57.650 ms - 35

@ankur-anand
Copy link
Owner

@kazhuyo The log shows you have a permission issue.

message: 'Request failed with status code 403', Try to check if the Consumer URL has proper access in the controller in case you are using different consumers.
https://github.com/kazhuyo/simple-sso/blob/master/sso-server/controller/index.js

Different consumers need to be explicitly allowed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants