GithubHelp home page GithubHelp logo

Comments (4)

omercs avatar omercs commented on June 18, 2024

ADAL handles cache/expiration for you. You need to set secret key for API<18 to setup encryption. Your app can derive pinpassword or ask user as well to make it more secure. App will set the derived key for encryption.
Are you using "acquireTokenByRefreshToken" to get a token? That will not cache the result and prompt will display for next acquireToken call.

from azure-activedirectory-library-for-android.

maxmironov avatar maxmironov commented on June 18, 2024

No, I use "acquireToken" method.
The flow is:

  1. User logs in and both tokens acquired.
  2. Access token expires.
  3. Refresh token is used to receive new access token and new refresh token, but refresh token is not acquired (has null value in AuthenticationResult).
  4. New access token expires.
  5. Refresh token is null so update fails and user is prompted to log in again.

As I can see, first it checks cache for access token. If it is absent/expired, AADAL checks for refresh token. If refresh token is valid it is used for update (AuthenticationContext.java#L675). When this scenario takes place I don't get new refresh token in AuthenticationResult.

from azure-activedirectory-library-for-android.

omercs avatar omercs commented on June 18, 2024

I could not get a repro for this. Can you send log entries for that?

from azure-activedirectory-library-for-android.

omercs avatar omercs commented on June 18, 2024

Recent code does not repro. Please open it if you repro.

from azure-activedirectory-library-for-android.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.