-
Notifications
You must be signed in to change notification settings - Fork 426
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
TypeError: cannot read properties of undefined (reading 'digest') in development environment #1320
Comments
Yes, this is related imho. @damienbod @linjie997 any ideas? |
Why not develop using https? This is simple to setup and then the development is more like the target system. I have not developed using http in a long time in any project of any type. This is the browser tools that you use and not the library. This is forced for a reason by Chrome. Greetings Damien |
Hello, |
the development environment that I found in the company had a hostname resolved through internal dns, after the error in the console I had the ssl certificates installed that we already had anyway and the services ported to https My idea was for someone inexperienced (since the error itself does not give much information) to display a warning in the console or to write it in the documentation |
What would be the best to write in the docs? Any suggestions? Then I can add it. |
I would write that the Angular application should be deployed in a 'secure origin', at least for Chrome (https, *, *) - HTTPS While for local development there is no problem |
@damienbod - this change (#1220) forced us to downgrade to version 12. To address this breaking change for Cordova/Ionic/Capacitor apps (#1220), may I suggest that we either make the JwtWindowCryptoService configurable (via config) and allow the definition of a version that uses jsrsasign? - and potential ship two versions (of JwtWindowCryptoService , e.g. JwtWindowCryptoService and JsrsJwtWindowCryptoService ) in the lib so it's an easy switch? |
I have run the V15 of this app successfully with capacitor, do you still have any problems there? |
Hi, i develop a pwa application. So i test app on mobile phone. I'm facing to this issue. Any idea to resolve it ? i didn't have this issue using another lib (angular-keycloak). I was switching from angular-keycloak to angular-auth-oidc-client to be 'more generic'. I wouldn't change again. I prefer work with this lib. I would like to access directly from my local network 192.168.x.x. For the moment, i use chrome:inspect with port forwarding (4200:localhost:4200) to have a successful login on the mobile phone. Thx in advance for any tips. |
Is your PWA using HTTPS? |
Yes for the production but not in development
Le mer. 8 févr. 2023 à 06:42, Fabian Gosebrink ***@***.***> a
écrit :
Is your PWa using HTTPS?
—
Reply to this email directly, view it on GitHub
<#1320 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AB2TLJL5CPYMRHFKXYARRADWWMW45ANCNFSM5JRGAGLA>
.
You are receiving this because you commented.Message ID:
***@***.***>
--
Jimmy Pannier
00337 71 255 930
www.lilletech.fr
Analyste-développeur / Freelance en services numériques
|
We also have a webpp, served from a Gateway, accessible in local mode from HTTP, and the library is not working. I tried to polyfill crypto.subtle but it's not that simple and the hack will be there for a long time. @FabianGosebrink The only option is to downgrade in v13 ? |
For this issue would you mind trying to change this flag on Chrome/Chromium based browsers? |
Hello @linjie997 , I'm sure it will work, but we can't ask our customers to activate this kind of flags in their browsers, and we cant control which browser they use. |
Hello, sorry I didn't understood it was local app available to customers. |
Thanks for your answer @linjie997 , self signed certificates are unfortunately not an option, so I guess the better option (for now) is to use v13.0.0. |
Hi @phillipzada , did you try the webcrypto-liner library as a polyfill when using HTTP as mentioned here ? |
Having the same problem on a Ionic Capacitor App on Android:
|
Describe the bug
If the environment (in my case the stage environment) is not setup as a a secure origin the library break up cause of the crypto library is not in window object
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Warning on library loading that check secure origin or a warning in documentation
Screenshots
Desktop (please complete the following information):
Additional context
https://chromium.googlesource.com/chromium/src/+/refs/heads/main/docs/security/faq.md#Which-origins-are-secure
https://www.chromium.org/blink/webcrypto
Maybe related to #1220
The text was updated successfully, but these errors were encountered: