wordjelly-auth 1.4.0 → 1.4.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/controllers/auth/admin_create_users_controller.rb +7 -9
- data/app/controllers/auth/application_controller.rb +1 -3
- data/app/controllers/auth/concerns/devise_concern.rb +5 -4
- data/app/controllers/auth/concerns/otp_concern.rb +7 -4
- data/app/controllers/auth/concerns/token_concern.rb +22 -10
- data/app/controllers/auth/profiles_controller.rb +1 -1
- data/app/controllers/auth/registrations_controller.rb +1 -7
- data/app/controllers/auth/sessions_controller.rb +0 -3
- data/app/models/auth/concerns/chief_model_concern.rb +1 -1
- data/app/models/auth/concerns/notification_concern.rb +0 -2
- data/app/models/auth/concerns/user_concern.rb +7 -6
- data/app/views/layouts/auth/navbar/_personalization.html.erb +0 -2
- data/config/initializers/devise.rb +16 -16
- data/config/initializers/omniauth.rb +11 -5
- data/lib/auth/notify.rb +1 -2
- data/lib/auth/two_factor_otp.rb +4 -0
- data/lib/auth/version.rb +1 -1
- data/lib/wordjelly-auth.rb +1 -1
- data/spec/dummy/app/assets/time_hashes.json +1 -1
- data/spec/dummy/app/controllers/topics_controller.rb +1 -1
- data/spec/dummy/app/models/noti.rb +1 -1
- data/spec/dummy/app/models/user.rb +2 -2
- data/spec/dummy/log/development.log +17 -0
- data/spec/dummy/log/test.log +97083 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/-0/-0dhrbY0GyOP-OwMgYIoIwx08gxlWeB6nRLgtQ-vhUs.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/-G/-G1nXy4LnP-1padJXRMq0gYex3KxVr9FeHvyjFhOxns.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/-c/-coZ9HrDBKWXMOPzHQVobptnxra-S-bwIwCqc_4IiEU.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/0S/0S3TQXmQdcOoHVbm1lf3TXSdtYp_W9PSeWflwASp-_U.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/12/12_GSJot0s_T9zQsZt4TwgVW7YyTAV1rOrKkMosmAqY.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/1U/1UcxcfcuuCi9V2eLzHmN0pyZTSdxjJePikHzuaBGsWE.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/1Z/1Z79eTYT4t733p8ELTIx1wetBTnyxNNk3wIMFXloO1M.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/1l/1lAmfBOdE8qRt9QMyGJDrt-FXCNUu9t9m2BtsGi8H-I.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/2T/2TCws4S9Q-TMgaH2pMlm-gKyxIr0-DrRA7JDOI_5wS8.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/31/31B_xMNizeQWxBfgWMxFwI19bbfTytpJFiXeoSOPuj8.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/3K/3KNpL9z0AyalQsOSPsnGkQEC2_lv54OQ8k2z92XHDk4.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/3q/3qusNC-PNAGtm0tVoy-OLbW0l6NDBnbr8h6HsC6-ZwE.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/40/40rH5cWLu9P-Ka9eaXaYLsiIMwo0lQU1uKJl87mmqp4.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/4k/4kGl3mzGAVt3OQrHipVrCTvobMGiNw1C3TAlM8d0jSo.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/5_/5_rNjsUQIG1kvx0Ea14xFiVUNZw-fQiCKFADtCUISl8.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/6P/6P2BRzaGXxd5wvxr6sWwgI1bZICtHCFMI6zQ_oZiOqk.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/7Y/7Y5LlLib_2JVdHyBWTD2jJE15HH6mBMmn-fO-4JFNVs.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/7u/7uFX_6SUih4Vpv_8-ugk1H7JpDXz1IvTpXI17HuSTbI.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/8J/8Jhgr_yvG58NUJCygqXHwkCHERvoyHhPOg10bYQy5nQ.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/8f/8foX5tYCyoYFpUsCT34-Bf6TpNNT6Kwd-XTv6aPxOhI.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/8t/8toCJcqwv4i9gl6liTXuXpsxiNatE-evUDcbHr0tz94.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/BD/BDfByD14hJgYaN0eTEfiFeGlD7GbA_ABSzDr6dSOgMk.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Bm/BmxJ5hMgr895pNBjWTXQDZBmV9BrSKILRBSs__eihb4.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Cc/CcHTIg-2JC1vRhuCXNydi-RfjziOF5qO8kYLj-HzoUA.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Cn/CnoShxpzz96vNVTeBqxA2k8ZBfnNHzHn2xIA7bD2jY4.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/DJ/DJKxp6-JgYXtFs0yhhjItwnj36wnlH0uS6GOnpL4BN0.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/D_/D_u3Rxnx5qB5j2rhRR0v7Fypt8j58ogFbmjh9QaL5Uc.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Do/Dot0LXvqeMyL06wXeUn8DLrURrTztIy1318Qraz4tNo.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Dz/Dz46sWpT9Is5wx29ihmFC0gW0wHKHFegvszl-ATyr04.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/E5/E5SBLFshplGNpTsaq2qbuLDLGUW5NX0W6G08orTEfb8.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/EB/EB3VH7Aqwf_pxOVmUvf4deSn_EF_00Pbs0aU-KVKrLU.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/EW/EW0mRGtnT3pbtHOhXnmfGFACMcet5Ga3wX7LvUZSub4.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Ev/Evd9M2zuKBBZJtuyjN_JKq5YMjyO87lr9NXlImL4t0E.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/F3/F3cZpkXnVS38KNxVg6GYRDXmAhGGY-40g1S6QS5xKnk.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/FY/FYMgeP_Bepfhv0u1xl0hcX3MyToXAa-jRzAFaX2eQ1w.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Fw/FwhDpPgbwLhSrMMUdzy_-ttvTTgXxEeDPefOGFfVVjg.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Fy/Fy9KYLBKO9dWxdcBNt4x1fu0Alk2d2bMSKfyVVxnEIU.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/G8/G8iu2dUItlF_pydVrIJh_wgC5atY6t_4tH1xoLHLrDc.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/J0/J0CfxOVkHAsR5OERX2QgPn-oNRq_1fAHhxavuGwpfJw.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Jc/Jc4nbds2iZUXo6dLvnHTM0olhT_NCm6w2VDKk_Wicx0.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Kq/KqrOZcHCPbn2wl5itOoIuGSL3lHJGjLnlNNiGqKSXik.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/LQ/LQRU7cqg6V9X5aetvUuLDZZn9nenW6SI-QzOKP5sCL0.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Lh/Lhl-3xF9pdODkFXSR0hrvXmI6ZAkvdbXxCPzAZnV5y4.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Lx/Lxs71Xh2V4O2qeyWbuEPCmkJfsRdlk13ONaYrE1n9wA.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/M-/M-xkCBgmq32eL5JZqjIxK6wtQXUq23nGa1XLpcuu1Qw.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/MK/MKZHzwCTzUN-wws9EwIUjppigKorRPKR9ZbtE92ayU8.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/MP/MPCPCXoDkqVYMarTQI6SHWsf6cnohji9-BQr4jK4HgE.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/NI/NI8qTKlBTJSRWwzDbRgXHQdclFZkYdOCjnSubTsR8q0.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/NZ/NZt2Fk8fjqCa38WUuIm3SVNE9pLABVJcLMwA73Aj75k.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Nm/NmKt9xXes3qjjL7qBoOgOfm3MzxgoF-bcIOSScOEj_A.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/OC/OCgU2H6mmLE7R1ly2ISlkKWR00THjG4oZpOICXgS6So.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/PB/PB-PxUvSlCbndtGCq5I-hPKgHO7TKMFukbldi6MnQA4.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/PB/PBHtjw1AR4rCnSGQ5LaH5J3n3z0lLq2y6UTj7Z0Pwtk.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/PT/PTgdtSaUOPELoOtDA34Sw4804A_el4Dm2j0rRA7cnFU.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Pq/PqVW--mUwbLir-XGjudr-ErZ6D9yfMsiYB6izLt0N8c.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Pt/PtM54QYZqornlZVQzg4zcRESJBwc1sqqkTaSNsmNcAs.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Q3/Q3CyfZaRjU5DIQuBAAhQOELbbj2DLEoFW_yKj_1hobQ.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Qv/QvTX_ppHbQG831XEDjBaxwq8CAjBVaLFNvY5xANghb4.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Qy/QyNeUuf3eE6ueqjRzWvtO4N93QgQnuQNc7B8yk8HYs4.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/RG/RGKD9rejvAJ0vOZYPxeU7ahImQUQ-Z4lmlm7sF3dLkg.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Rs/Rs9BnF25JQdTl4JaucXLu0xkTuJ3ejZFt3A_D25zXqQ.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/SV/SVkbUossZ05MhBUc3oKmndn5ZOKrfUXYmiFcADiGctI.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Si/SiiD3tf3KNQA5hnNKIkL--jUSORyEVH7mUmjBN4z9ic.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/T1/T1nKgCtKoK7k7opWfcmRpkyetldn-pb1ZhbRjluCy2I.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Ti/TieOlds8L-CqvMqVFup3GtbotBBsO0q-6_gNt9zTFGo.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Un/UnGq_QfVsYWG6no7Jgp0uPY-gCpasdjwNRUrqbaMNAI.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Uw/Uw-q52a_hUiyV6sSnGaYy2db4clS3pvnzG1TKRbpL8Y.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Uy/UyWRUz3W6gylcdAVgiRRpaUZL4O5miHh4jmX7o-1xg4.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/VI/VIonoCAtoPJEHyodwQkwp611LZtr3jHG4LzC-F1hF84.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Vh/VhxsJpfat6UsgoVQCQg1Ym2FYDXUOH78NLF3d0FuJS4.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Vn/VnIG8lgvhZr2Si37Q-bUrMpVb_zDw_7uMKITTO-ovU0.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Vv/VvQbcrRv_qDg5JPUweKJ-vcVRJDgkkuOHioRSsKEEbc.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/WJ/WJ-e2Z8tTnmWXlQXwUI8EZnB90yGiFMYtTfxpK2gOvU.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Wn/WnkRWDYrvGLVMSb-D3I7dmRiIwFqpXNm38q9fJERlCk.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/X3/X3smAVji-ukCfsZEDAxoOZLpw8mT4Mj-fAbNVG9-9bQ.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/X9/X9b8M0d2usej58k1zoDmbBdjSdBhN0x1QtWhmnh-JG4.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Y9/Y9aAK1BuseBw1dCFf7663-37yVBgaRYvksiZ2KJSfvk.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/YJ/YJdLwUSTqw6BkhdtdMgfjMSdelN2-81K7efXUW6jRJU.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/YS/YSq1BFD3X5FC7M_habJoT5avPD2YdPLqr0sR1wWWAvk.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Ye/Yeod13x4QZ_yg24AXWAplizzEeT4vmYpFaW-8ByTAyI.cache +4 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Zl/Zl-FTV4vKa2r3nBU7NRBdlkyRgcIo7NOyqsfaqdX_fg.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/Zz/ZzHkXwTsIIQP9RxHuaUK5e7dLIn-97MEMx4FIMfTeQ4.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/_p/_pMJDnS03nKNwhX6yRLzcNGVCbhacORKScShrSx7MxI.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/_p/_pS1zE8_3SWBv08G8D0PbOrKWwWlu1J-10DIcKTkgO0.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/aU/aUdedQfJRE4WM1yhkBqntdEdsLi9Afvy4vJCZT_HC1o.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/aW/aWvPO8gLdbq7hPlaVWsmAjqBaF8YSdYy037mMDXW4Tg.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/ai/aif0HXHTP8TTkJLP5WgJJWRX-3WuhyXitAQqKggdkcI.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/bZ/bZTOj3FkHGhajkYgEen2owanSvTPSosjpiW1XxECilw.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/c6/c6AR_6VzNekyDzXLdRhwvHoXWWbn09mT5UNPBqF8UpA.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/c_/c_h7t7u_rFR3KnBBfzFsDc4YAUt0EZTw96CPQ1kLFf8.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/cm/cmQOyDMGQlBXxS-cEfW3ybQyDtYbA_ELFjyA2HMV7rs.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/cs/csUv0EfXstJ9ICGSfTaFbGDO-dOXno_sHKVEKyM_Nhc.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/dH/dHiZ5z2yXwZwOieEvpwWUUaKghyAC0iCIjW2q2kVeUE.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/dJ/dJRQPj1XGX75PaQ17AgiKl5kyCK6bV7ylMbbMqbXuco.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/dZ/dZMQcf9OWIgXcTJCJ1GTVDVe19S9ZgiG_1e1a780d_Q.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/dq/dqNP-F6bmkWZMlXgf-329jtqOGCKF2oXUvNr5bhPbQE.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/dz/dzuY7AKX-enWr0rYgYH4OXHi-LBvc0isw5ie0yO45e4.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/f8/f88N5DXkOKgPc-nGhMPxgpspka0NaeEVCBzGvwaE8BM.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/fa/faDulrH9S1Be0m8ztxG5g5ynbRBVxf70wOB6vrVMywE.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/gp/gpFDoJpjw_aE4DhvaqWOaFhXiqIvF0WSfjTnl8Q3G0U.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/im/im4F5IlDskeBDAqDQULkPwTLhrSZJ_tYk1TmHmRujjg.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/iv/ivDNGgRa-TXRJNXFJu1KUl5gfJXv6A3HJck8dhCMDrs.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/ix/ixuoKIlw0Kp3KfosOL87jmUF47SvtIQB-3P-Klex8go.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/jc/jcHgYxE_SR00sIQslkTchNwH3zBVkUuEI8ePXqylmHQ.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/jl/jlRTXjvTvwfw694lhUYco9VNQ5p9wUZjcNZPw4DBkH4.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/k3/k35ajM7sLMUFU8Q0Eicz8ll4aAuVA7vaOR2ZZRKYl6M.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/l-/l-AjdVtB_eIbbSI8T3oY9RxX6MaokgElNwezpCrU0tc.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/nL/nLc7sVZTvR9ZySmCVbOm3L11K3OIFglLjTfR_wfqP1Y.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/nN/nNDg8M6LNx27UKt--_qjy5w3B3w2ZQXfVHofJ_9iOIc.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/o8/o8zU5S5FxBlyHKTWbAxaZSS96PBkQFKJtsQpJGhPevk.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/o9/o9gxmoLOIG_-nCNB7oRpVgRr6i--xBUWFKgKjtKV2sc.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/oR/oRrswfAuldTZ9brG64pYLewt9Zi99QOmMXZ0lyGv708.cache +5 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/oj/ojEGth9PSl5TGslt-isut9GtJZpuhewIjzV05sVKEkI.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/pB/pBtiG2EBPXNZ0lpzVX6g6hZKKImEJfIsdNfhJWYX-iw.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/pO/pO79DiFftJguHoaUHA9OkE73QnTLdyxEs_UwCXXClcg.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/qI/qIFKqiroYFomfrmRXac4nF_0AsVorETB_bIagFIbkcM.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/qu/qu6F54GREhiOp_2P6ppQ-8NeZsYlveIvYKQlgXcghts.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/r6/r64nn_NhSInz6BbD3EDCK2I-gTTY4g-B0RHgrv_SJ_A.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/rA/rAcSMdSYlR0BYo0DfMZrKdbZa-LIFyzsOyUM6tQZ0QA.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/rf/rfrwzmCwUJdLJ-4vW6Ho4n9OHtskPdrp1Sgxp8nfXO0.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/sz/szhmMT4rk7_w_vcKplrRBR85_r8aYTZ1E7QjasY2wj0.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/t8/t8pUdgZt9yH9zIp1WN65Ir9roY_7kopnPOKJnvc2K3U.cache +1 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/tE/tEAobslXA32fbcT6i-lf-ZgKlWdPkLAUVJHOEq9AhBI.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/u9/u9ZAscd165iXfdEDwmQPbzClIh27yl1HRrn-q6t0EI0.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/uk/uk213HHY3gnm65Jj-SGfFcXcE_Q7YODVkxGDTefhmVw.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/um/um5UeEadQEOsdN0EQQ4yZykW5lqFUPQ5_FUjcRFnQGs.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/v5/v5g7KRwDAbcVPwY2UBAXijZMNgKyeP-OfIsGKP_7cmc.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/vF/vFVA03FCooxk6TthEgHU4yFupx8t23TwrrmX7J5tCUE.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/vP/vPke4WY2P8qj5V60qX_NWSeiVn8v2Q6HTwko-0aoa8s.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/vv/vv77r1oYAYIEYc9esC2Pm0Yko7f4iiDqQD62ys6nCX4.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/vz/vzZSiCj2ChRKhiv1haund-oihmd8SXK0ENbEzBEMsF4.cache +0 -0
- data/spec/dummy/tmp/cache/assets/sprockets/v3.0/yC/yCS_vzjBPPIXrHoNaiFsaH4r4OR6nI9I0i0XnY-ZjvA.cache +0 -0
- data/spec/rails_helper.rb +9 -0
- data/spec/requests/user/additional_login_param_and_email_validation_spec.rb +19 -19
- data/spec/requests/user/admin_create_user_request_spec.rb +51 -25
- data/spec/requests/user/client_request_spec.rb +2 -2
- data/spec/requests/user/confirmation_request_spec.rb +12 -12
- data/spec/requests/user/omniauth_callbacks_request_spec.rb +30 -32
- data/spec/requests/user/otp_basic_flow_request_spec.rb +28 -28
- data/spec/requests/user/password_request_spec.rb +19 -19
- data/spec/requests/user/registration_request_spec.rb +54 -48
- data/spec/requests/user/session_request_spec.rb +28 -30
- data/spec/requests/user/token_request_spec.rb +58 -85
- data/spec/requests/user/unlock_request_spec.rb +8 -8
- data/spec/spec_helper.rb +3 -0
- metadata +205 -57
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e8b9a7732006538788000f0f4bc628b26f0b0d76867ee2d8454b69a06133451a
|
4
|
+
data.tar.gz: 4f30284e7d804e450394e02da9e3b45e19e594927c4b272f879250e162c87f3e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: '09d068fd538fc155fd7fda4df5f3ec0ed872b94ebcf2d86f5c2884809ea2816ff1639f60d37b57497f29be33b6fd1640e5668f68657444ac5a9a1707df0c7e75'
|
7
|
+
data.tar.gz: 7576dfbbd10f34f41dbd5ec685d86d3e3d465d7b9c58b5bba13f8bb2b3d524f3e947b2ac784805095dd1c8e49ceb11a7be1eec07c467c603da83e2cf01183071
|
@@ -1,13 +1,14 @@
|
|
1
1
|
class Auth::AdminCreateUsersController < ApplicationController
|
2
2
|
## only these actions need an authenticated user to be present for them to be executed.
|
3
|
+
|
3
4
|
CONDITIONS_FOR_TOKEN_AUTH = [:create,:update,:destroy,:edit,:new,:index,:show]
|
4
5
|
TCONDITIONS = {:only => CONDITIONS_FOR_TOKEN_AUTH}
|
5
6
|
include Auth::Concerns::DeviseConcern
|
6
7
|
include Auth::Concerns::TokenConcern
|
7
|
-
|
8
|
-
|
8
|
+
before_action :do_before_request , TCONDITIONS
|
9
|
+
before_action :initialize_vars , TCONDITIONS
|
9
10
|
## ensures that only admin users.
|
10
|
-
|
11
|
+
#before_action :is_admin_user , TCONDITIONS
|
11
12
|
|
12
13
|
|
13
14
|
## called before all the actions.
|
@@ -45,14 +46,11 @@ class Auth::AdminCreateUsersController < ApplicationController
|
|
45
46
|
# User.where(:email => "bhargav.r.raut@gmail.com").first.delete
|
46
47
|
# POST /auth/admin_create_users
|
47
48
|
def create
|
48
|
-
|
49
|
+
k = SecureRandom.hex(24)
|
50
|
+
@auth_user.password = k
|
51
|
+
@auth_user.password_confirmation = k
|
49
52
|
@auth_user.m_client = self.m_client
|
50
53
|
@auth_user.created_by_admin = true
|
51
|
-
|
52
|
-
## we will have to set the m_client.
|
53
|
-
## but what if that client is different from the client that was used to create the user?
|
54
|
-
## no this will not happen here.
|
55
|
-
## here we will only create.
|
56
54
|
respond_to do |format|
|
57
55
|
if @auth_user.save
|
58
56
|
if !@auth_user.additional_login_param.blank?
|
@@ -8,7 +8,7 @@ module Auth
|
|
8
8
|
respond_to do |format|
|
9
9
|
format.json {render json: {:errors => e.to_s}, status: 422}
|
10
10
|
format.js {render :partial => "auth/modals/resource_errors.js.erb", locals: {:errors => [e.to_s]}}
|
11
|
-
format.html {render :
|
11
|
+
format.html {render :plain => e.to_s.html_safe}
|
12
12
|
end
|
13
13
|
end
|
14
14
|
|
@@ -160,7 +160,5 @@ module Auth
|
|
160
160
|
puts Rails.application.routes.url_helpers.to_s
|
161
161
|
end
|
162
162
|
|
163
|
-
|
164
|
-
|
165
163
|
end
|
166
164
|
end
|
@@ -43,7 +43,7 @@ module Auth::Concerns::DeviseConcern
|
|
43
43
|
|
44
44
|
def ignore_json_request
|
45
45
|
if is_json_request?
|
46
|
-
|
46
|
+
head 406
|
47
47
|
end
|
48
48
|
end
|
49
49
|
|
@@ -139,15 +139,16 @@ module Auth::Concerns::DeviseConcern
|
|
139
139
|
#puts "action name is something else."
|
140
140
|
if session[:client].nil?
|
141
141
|
puts "cient is nil so rendering nothing."
|
142
|
-
render :nothing => true , :status => :unauthorized
|
143
|
-
|
142
|
+
#render :nothing => true , :status => :unauthorized
|
143
|
+
head :unauthorized
|
144
|
+
else
|
144
145
|
|
145
146
|
end
|
146
147
|
end
|
147
148
|
else
|
148
149
|
|
149
150
|
if verify_authenticity_token == false
|
150
|
-
|
151
|
+
head :unauthorized
|
151
152
|
end
|
152
153
|
end
|
153
154
|
end
|
@@ -4,17 +4,20 @@ module Auth::Concerns::OtpConcern
|
|
4
4
|
included do
|
5
5
|
include Auth::Concerns::DeviseConcern
|
6
6
|
##refer to auth/applicationcontroller for the not_found def, and its rescue block.
|
7
|
-
|
8
|
-
|
9
|
-
|
7
|
+
before_action :do_before_request
|
8
|
+
before_action :initialize_vars
|
9
|
+
before_action :check_recaptcha, only: [:send_sms_otp,:verify_otp]
|
10
10
|
|
11
11
|
end
|
12
12
|
|
13
13
|
def initialize_vars
|
14
14
|
##deep symbolize the incoming params after passing through permitted params.
|
15
15
|
|
16
|
-
@resource_params = permitted_params
|
16
|
+
@resource_params = permitted_params
|
17
17
|
|
18
|
+
puts "the resoure params are:"
|
19
|
+
puts @resource_params.to_s
|
20
|
+
|
18
21
|
##if the resource is defined, assign the class and the symbol for use further in the file
|
19
22
|
##eg: resource is provided in the route as : users, so
|
20
23
|
##@resource_class => User
|
@@ -4,10 +4,11 @@ module Auth::Concerns::TokenConcern
|
|
4
4
|
extend ActiveSupport::Concern
|
5
5
|
|
6
6
|
included do
|
7
|
-
|
7
|
+
|
8
|
+
|
8
9
|
attr_accessor :authentication_done
|
9
10
|
|
10
|
-
TCONDITIONS
|
11
|
+
TCONDITIONS = {:only => [:show]} unless defined? TCONDITIONS
|
11
12
|
LAST_FALLBACK = :devise unless defined? LAST_FALLBACK
|
12
13
|
|
13
14
|
|
@@ -17,12 +18,17 @@ module Auth::Concerns::TokenConcern
|
|
17
18
|
## how many models are defined in the preinitializer
|
18
19
|
auth_resources_count = Auth.configuration.auth_resources.size
|
19
20
|
|
20
|
-
|
21
|
+
puts "auth_resources count:"
|
22
|
+
puts auth_resources_count.to_s
|
23
|
+
res = Auth.configuration.auth_resources.keys[0]
|
24
|
+
puts "the TCONDITIONS ARE: #{self::TCONDITIONS}"
|
25
|
+
#acts_as_token_authentication_handler_for(res.constantize,Auth.configuration.auth_resources[res].merge({:fallback => self::LAST_FALLBACK}).merge(self::TCONDITIONS || {}))
|
26
|
+
|
21
27
|
## if we have more than one auth resource model.
|
22
28
|
if auth_resources_count > 1
|
23
29
|
## take all of them except the last, and add the fallback as none to them.
|
24
30
|
## also merge the controller level conditions defined above.
|
25
|
-
|
31
|
+
puts "there is more than one."
|
26
32
|
Auth.configuration.auth_resources.keys.slice(0,auth_resources_count - 1).each do |res|
|
27
33
|
|
28
34
|
acts_as_token_authentication_handler_for(res.constantize,Auth.configuration.auth_resources[res].merge({:fallback => :none}).merge(self::TCONDITIONS))
|
@@ -39,14 +45,20 @@ module Auth::Concerns::TokenConcern
|
|
39
45
|
else
|
40
46
|
## in case there is only one authentication resource, then the conditions are like the last one in case there are multiple(like above.)
|
41
47
|
res = Auth.configuration.auth_resources.keys[0]
|
42
|
-
|
48
|
+
#puts "the last resource is:"
|
49
|
+
#puts "the action is: #{action_name}"
|
50
|
+
#puts res.to_s
|
51
|
+
#puts "conditions are:"
|
52
|
+
puts res.constantize,Auth.configuration.auth_resources[res].merge({:fallback => self::LAST_FALLBACK}).merge(self::TCONDITIONS || {})
|
43
53
|
acts_as_token_authentication_handler_for(res.constantize,Auth.configuration.auth_resources[res].merge({:fallback => self::LAST_FALLBACK}).merge(self::TCONDITIONS || {}))
|
44
|
-
|
54
|
+
#puts "crosses token auth handler"
|
45
55
|
end
|
46
|
-
|
56
|
+
|
57
|
+
|
47
58
|
end
|
48
59
|
|
49
|
-
|
60
|
+
|
61
|
+
before_action :set_resource
|
50
62
|
|
51
63
|
## made this a helper so that it can be used in views as well.
|
52
64
|
helper_method :lookup_resource
|
@@ -60,7 +72,7 @@ module Auth::Concerns::TokenConcern
|
|
60
72
|
## basically a convenience method to set @resource variable, since when we have more than one model that is being authenticated with Devise, there is no way to know which one to call.
|
61
73
|
def set_resource
|
62
74
|
|
63
|
-
|
75
|
+
puts "--------------------came to set resource."
|
64
76
|
|
65
77
|
Auth.configuration.auth_resources.keys.each do |resource|
|
66
78
|
break if @resource = self.send("current_#{resource.downcase}")
|
@@ -78,7 +90,7 @@ module Auth::Concerns::TokenConcern
|
|
78
90
|
|
79
91
|
|
80
92
|
def lookup_resource
|
81
|
-
|
93
|
+
puts "came to lookup resource."
|
82
94
|
## if the current signed in resource si not an admin, just return it, because the concept of proxy arises only if the current_signed in resource is an admin.
|
83
95
|
#puts "current signed in resource : #{current_signed_in_resource}"
|
84
96
|
return current_signed_in_resource unless current_signed_in_resource.is_admin?
|
@@ -1,22 +1,16 @@
|
|
1
1
|
class Auth::RegistrationsController < Devise::RegistrationsController
|
2
2
|
|
3
|
-
TCONDITIONS = {:only => [:update,:destroy]}
|
3
|
+
TCONDITIONS = {:only => [:update,:destroy,:show]}
|
4
4
|
|
5
5
|
include Auth::Concerns::TokenConcern
|
6
6
|
|
7
7
|
#before_action :check_recaptcha, only: [:create, :update]
|
8
8
|
|
9
|
-
|
10
9
|
def create
|
11
|
-
#puts "CAME TO CREATE."
|
12
|
-
#puts "sign up params."
|
13
|
-
#puts sign_up_params
|
14
10
|
check_recaptcha
|
15
11
|
build_resource(sign_up_params)
|
16
12
|
resource.m_client = self.m_client
|
17
13
|
resource.set_client_authentication
|
18
|
-
#puts "resource attributes are:"
|
19
|
-
#puts resource.attributes.to_s
|
20
14
|
resource.save
|
21
15
|
yield resource if block_given?
|
22
16
|
if resource.persisted?
|
@@ -7,7 +7,7 @@ module Auth::Concerns::ChiefModelConcern
|
|
7
7
|
|
8
8
|
include Mongoid::Document
|
9
9
|
include Mongoid::Timestamps
|
10
|
-
include Mongoid::EmbeddedErrors
|
10
|
+
#include Mongoid::EmbeddedErrors
|
11
11
|
include Auth::Concerns::CloneConcern
|
12
12
|
include Auth::Concerns::ImageLoadConcern
|
13
13
|
## expected to be a hash with names of callbacks and boolean values.
|
@@ -156,8 +156,6 @@ module Auth::Concerns::NotificationConcern
|
|
156
156
|
end
|
157
157
|
|
158
158
|
################### SEND SMS NOTIFICATION ####################
|
159
|
-
|
160
|
-
|
161
159
|
## defaults to just sending the sms direclty.
|
162
160
|
## override using a background job to actually call the send_sms method.
|
163
161
|
def send_sms_background(resource)
|
@@ -862,6 +862,7 @@ module Auth::Concerns::UserConcern
|
|
862
862
|
## now first we are going to test it with the ui.
|
863
863
|
## and we are going to test it with one admin and one non admin account
|
864
864
|
## before that, we are going to
|
865
|
+
## personality class kaha se ayega bhosadike?
|
865
866
|
def set_secondary_links
|
866
867
|
unless self.secondary_links["Add New Account"]
|
867
868
|
self.secondary_links["Add New User"] = {
|
@@ -886,13 +887,13 @@ module Auth::Concerns::UserConcern
|
|
886
887
|
end
|
887
888
|
|
888
889
|
## switch to the user, and see all associated people.
|
889
|
-
|
890
|
-
|
891
|
-
|
892
|
-
|
893
|
-
|
890
|
+
unless Auth.configuration.personality_class.blank?
|
891
|
+
unless self.secondary_links["See All Associated People"]
|
892
|
+
self.secondary_links["See All Associated People"] = {
|
893
|
+
:url => Rails.application.routes.url_helpers.send(Auth::OmniAuth::Path.create_or_index_path(Auth.configuration.personality_class))
|
894
|
+
}
|
895
|
+
end
|
894
896
|
end
|
895
|
-
|
896
897
|
end
|
897
898
|
|
898
899
|
end
|
@@ -2,7 +2,6 @@
|
|
2
2
|
<span id="personalization_nav_links">
|
3
3
|
<%= content_for(:personalization_nav_links) if content_for?(:personalization_nav_links) %>
|
4
4
|
</span>
|
5
|
-
<li><%= link_to "Products", products_path %></li>
|
6
5
|
<li data-resource-singular="<%= current_res.class.name.downcase %>" data-resource="<%= Auth.configuration.mount_path[1..-1] + "/" +current_res.class.name.downcase.pluralize %>"><%= link_to "Account Settings", edit_res_registration_path,:class => "profile_nav_option" %></li>
|
7
6
|
<li data-resource-singular="<%= current_res.class.name.downcase %>" data-resource="<%= Auth.configuration.mount_path[1..-1] + "/" +current_res.class.name.downcase.pluralize %>"><%= link_to "Profile", profile_path({:id => current_res.id, :resource => current_res.class.name.downcase.pluralize}),{:class => "profile_nav_option"} %></li>
|
8
7
|
<li><%= link_to('Sign Out', destroy_res_session_path, :method => :delete, id: "sign_out") %></li>
|
@@ -11,7 +10,6 @@
|
|
11
10
|
<% Auth.configuration.auth_resources.keys.each do |res| %>
|
12
11
|
<% if Auth.configuration.auth_resources[res][:nav_bar] %>
|
13
12
|
<li class="sign_in_nav_option" data-resource-singular="<%=res.downcase %>" data-resource="<%= Auth.configuration.mount_path[1..-1] + "/" + res.downcase.pluralize %>"><a href="#">Sign In</a></li>
|
14
|
-
<li><%= link_to "Products", products_path %></li>
|
15
13
|
<% end %>
|
16
14
|
<% end %>
|
17
15
|
<% end %>
|
@@ -280,7 +280,6 @@ end
|
|
280
280
|
DeviseController.class_eval do
|
281
281
|
|
282
282
|
|
283
|
-
|
284
283
|
include Auth::Concerns::DeviseConcern
|
285
284
|
|
286
285
|
##add to devise concern.
|
@@ -346,14 +345,13 @@ DeviseController.class_eval do
|
|
346
345
|
end
|
347
346
|
end
|
348
347
|
|
349
|
-
def render(*args)
|
350
348
|
|
349
|
+
def render(*args)
|
351
350
|
cli = session[:client]
|
352
351
|
if (session[:client] && (session[:client].is_a? Hash))
|
353
352
|
cli = Auth::Client.new(session[:client])
|
354
353
|
end
|
355
354
|
|
356
|
-
|
357
355
|
#if resource && resource.set_client_authentication?(action_name,controller_name,cli)
|
358
356
|
# resource.set_client_authentication(cli)
|
359
357
|
#end
|
@@ -370,7 +368,6 @@ DeviseController.class_eval do
|
|
370
368
|
|
371
369
|
redirect_to (session.delete(:redirect_url) + "?authentication_token=" + resource.authentication_token + "&es=" + curr_app_es)
|
372
370
|
else
|
373
|
-
|
374
371
|
super(*args)
|
375
372
|
end
|
376
373
|
end
|
@@ -380,35 +377,38 @@ DeviseController.class_eval do
|
|
380
377
|
|
381
378
|
##add to devise_concern.
|
382
379
|
def require_no_authentication
|
383
|
-
|
380
|
+
puts "------------ CAME TO REQUIRE NO AUTH ---------------"
|
381
|
+
puts "action is:#{action_name}"
|
384
382
|
do_before_request
|
385
|
-
|
383
|
+
puts "came past do before request."
|
386
384
|
|
387
385
|
assert_is_devise_resource!
|
388
|
-
|
386
|
+
puts "came past assert is devise resource"
|
389
387
|
|
390
388
|
|
391
389
|
return unless is_navigational_format?
|
392
390
|
|
393
|
-
|
391
|
+
puts "came past is navigational format."
|
394
392
|
|
395
393
|
no_input = devise_mapping.no_input_strategies
|
396
|
-
|
394
|
+
puts "no input is: #{no_input}"
|
397
395
|
|
398
396
|
|
399
397
|
authenticated = if no_input.present?
|
400
398
|
args = no_input.dup.push scope: resource_name
|
401
|
-
|
399
|
+
puts "authenticated already."
|
402
400
|
warden.authenticate?(*args)
|
403
401
|
else
|
404
|
-
|
402
|
+
puts "check if authenticated"
|
405
403
|
warden.authenticated?(resource_name)
|
406
404
|
end
|
407
405
|
|
408
|
-
|
406
|
+
puts "came past autnenticated."
|
407
|
+
puts "authenticated is: #{authenticated}"
|
408
|
+
puts "Resource is: #{resource}"
|
409
409
|
if authenticated && resource = warden.user(resource_name)
|
410
410
|
if @redirect_url.nil?
|
411
|
-
|
411
|
+
puts "came to failure."
|
412
412
|
flash[:alert] = I18n.t("devise.failure.already_authenticated")
|
413
413
|
redirect_to after_sign_in_path_for(resource)
|
414
414
|
else
|
@@ -453,7 +453,7 @@ module Devise
|
|
453
453
|
##otherwise we do nothing.
|
454
454
|
def verify_signed_out_user
|
455
455
|
if is_json_request?
|
456
|
-
|
456
|
+
head 406 and return
|
457
457
|
end
|
458
458
|
if all_signed_out?
|
459
459
|
set_flash_message! :notice, :already_signed_out
|
@@ -488,7 +488,7 @@ module Devise
|
|
488
488
|
|
489
489
|
if resource.errors.empty?
|
490
490
|
if is_json_request?
|
491
|
-
|
491
|
+
head 201 and return
|
492
492
|
end
|
493
493
|
set_flash_message! :notice, :unlocked
|
494
494
|
respond_with_navigational(resource){ redirect_to after_unlock_path_for(resource) }
|
@@ -515,7 +515,7 @@ module Devise
|
|
515
515
|
if resource.errors.empty?
|
516
516
|
set_flash_message!(:notice, :confirmed)
|
517
517
|
if is_json_request?
|
518
|
-
|
518
|
+
head 201 and return
|
519
519
|
else
|
520
520
|
##when we have first signed into the accoutn, and then we want to change the email, then when we click the confirmation link for the new email, in that case, we cannot set the resource to nil, since the user is already signed in, so we do this check to see if who we have signed in , is the same as the user who has confirmed, and in that case, we just let things proceed.
|
521
521
|
current_resource = self.send("current_#{self.resource.class.name.downcase.to_s}")
|
@@ -334,6 +334,10 @@ module OmniAuth
|
|
334
334
|
## #callback_url -> ref to it in #http://www.rubydoc.info/github/intridea/omniauth-oauth2/OmniAuth/Strategies/OAuth2#callback_url-instance_method
|
335
335
|
## that method calls 'full_host', but that may be the wrong host, especially in case of above mentioned android issue.
|
336
336
|
## make sure that the host you specify in Auth.configuration
|
337
|
+
puts "host name: #{Auth.configuration.host_name}"
|
338
|
+
puts "script name: #{script_name}"
|
339
|
+
puts "callback path: #{callback_path}"
|
340
|
+
|
337
341
|
url_to_pass_as_callback = Auth.configuration.host_name + script_name + callback_path
|
338
342
|
|
339
343
|
|
@@ -432,7 +436,9 @@ module SimpleTokenAuthentication
|
|
432
436
|
## but then the gem attempts authentication of the second model also, and failing that, triggers the not authenticated fallback.
|
433
437
|
## to prevent that from happening, we ignore the fallback if we are already signed in.
|
434
438
|
def fallback!(entity, fallback_handler)
|
435
|
-
|
439
|
+
|
440
|
+
puts "came to fallback!"
|
441
|
+
|
436
442
|
return if self.signed_in?
|
437
443
|
|
438
444
|
fallback_handler.fallback!(self, entity)
|
@@ -472,17 +478,17 @@ module SimpleTokenAuthentication
|
|
472
478
|
|
473
479
|
def find_record_from_identifier(entity)
|
474
480
|
## you are supposed to find the record using one of the other parameters.
|
475
|
-
|
481
|
+
puts "came to find entity from identifier -----------------------------------"
|
476
482
|
additional_identifiers = entity.get_additional_identifiers_from_headers(self)
|
477
483
|
|
478
|
-
|
479
|
-
|
484
|
+
puts "additional_identifiers"
|
485
|
+
puts additional_identifiers
|
480
486
|
|
481
487
|
app_id_value = additional_identifiers["X-User-Aid"]
|
482
488
|
user_es_value = additional_identifiers["X-User-Es"]
|
483
489
|
token = entity.get_token_from_params_or_headers(self)
|
484
490
|
|
485
|
-
|
491
|
+
puts "token:#{token}"
|
486
492
|
|
487
493
|
if token
|
488
494
|
|