Tag:JWT authentication token

  • . net # core # API interface JWT authentication token

    Time:2022-4-29

    1、 Project > manage nuget package installation 2、 appsettings. JSON add “JWT”: { “Secret”: “~! @#$% ^ & * () qwertyuiopasldkh[o51485421ajshk ^% *) Kasd”, // key “Issuer”: “kfjdhf”, // issuer “Audience”: “kfjdhf”, // receiver //”Expired”: 30 // expiration time (30min) } 3、 Configureservices injection JWT #Region register JWT //Get profile var JWTConfig = Configuration.GetSection(“JWT”); //Generate […]