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

Support HTTP authentication for updating package lists and downloading packages #2761

Closed
eamsden opened this issue Aug 13, 2015 · 10 comments
Closed

Comments

@eamsden
Copy link

eamsden commented Aug 13, 2015

Users running private Hackage instances may wish to reverse proxy though a server that provides HTTP authentication. Cabal should be configurable with per-repository usernames and passwords to provide to repository servers when asked for authentication. This, in conjunction with #2760, would provide a great deal more security for users running private Hackage instances.

@eamsden eamsden mentioned this issue Aug 13, 2015
@23Skidoo
Copy link
Member

Cabal should be configurable with per-repository usernames and passwords to provide to repository servers when asked for authentication.

IIRC this is implemented in HEAD.

@eamsden
Copy link
Author

eamsden commented Aug 13, 2015

@23Skidoo can you point to a commit? I found the one for adding HTTPS support but not the one for doing auth on cabal update and downloading packages...

@23Skidoo
Copy link
Member

I was thinking of #2627.

not the one for doing auth on cabal update and downloading packages...

Right, this is not implemented.

eamsden pushed a commit to plow-technologies/cabal that referenced this issue Aug 14, 2015
@eamsden
Copy link
Author

eamsden commented Aug 14, 2015

I've opened pull request #2764 which fixes the call to wget so that passwords are not filtered from the URL. This allows the use of http-transport: wget and username/password info in the repo url. @23Skidoo would you mind looking at it and merging it?

@DemiMarie
Copy link

Sending the password in the URL is a very bad idea — much infrastructure assumes that URLs are not confidential and they are almost certain to be logged, etc. Instead, the password must be sent separately from the URL. Furthermore, sending a password over plaintext HTTP should be disabled.

@23Skidoo
Copy link
Member

Sending the password in the URL is a very bad idea

Right. The top-level username and password fields should be deprecated and made a part of the repository section.

@ezyang
Copy link
Contributor

ezyang commented Oct 25, 2016

Do we have anyone committed to making this happen for 2.0? This doesn't seem like a blocker.

@23Skidoo
Copy link
Member

Do we have anyone committed to making this happen for 2.0?

Don't think so.

@fgaz
Copy link
Member

fgaz commented Sep 11, 2021

Is this fixed by #7630?

@gbaz
Copy link
Collaborator

gbaz commented Sep 11, 2021

I think it was half-fixed already (for wget) and now that fixes it with curl, which should suffice!

Note that the above concern about passwords not getting sent in the url is fine, afaik -- i.e. they're specified in the url in the syntax, but the transport handling handles them separately.

@gbaz gbaz closed this as completed Sep 11, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants