Skip to content
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

ToJSON for URI includes passwords #1115

Open
ezrakilty opened this issue Aug 27, 2024 · 0 comments
Open

ToJSON for URI includes passwords #1115

ezrakilty opened this issue Aug 27, 2024 · 0 comments

Comments

@ezrakilty
Copy link

The instance of ToJSON given for Network.URI objects passes id for the function that is intended to sanitize passwords out of the UserInfo field of a URI, meaning that by default uses of this instance will include any password in the output:

toJSON uri = toJSON (URI.uriToString id uri "")

There will be many cases where users probably do want to serialize the password component of a URI, but it is perhaps not a good default. What do you think?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant