r/programminghelp • • Apr 10 '22

React Can React State or Context be hacked?

chop deserve sort knee squeal cooing makeshift attraction physical sharp

This post was mass deleted and anonymized with Redact

4 Upvotes

4 comments sorted by

1

u/serg06 Apr 10 '22

Storing a user's password in context is pretty unconventional. Usually you'd store an authentication token or JWT, not their password directly.

I am just curious if react state or context can be attained by people with malicious intents.

I mean, it's not supposed to be obtainable, but a malicious browser extension or a Chrome vulnerability could always expose it.

1

u/Ok_Abroad9642 Apr 10 '22 edited Oct 13 '25

public scary cough paltry dependent provide jar fade amusing husky

This post was mass deleted and anonymized with Redact

1

u/jasonmhhq Jul 07 '22

I am actually wondering the same thing. I'm building a database with react and I don't want to store the jwt in local storage since it is possible to be accessed. I was thinking of using global state to store it.

Have you found the answer to your question yet?

1

u/Ok_Abroad9642 Jul 10 '22 edited Oct 13 '25

skirt relieved scale towering humor live rainstorm truck memorize gray

This post was mass deleted and anonymized with Redact