Fix CR prompt with --auth-user-pass + R from a file
Get series with b4
b4 am [email protected]...Versions newest first
- v1 Latest2 patches 2 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | Fix CR prompt with --auth-user-pass & support reading response.doc/ src/ | +29 | 14 replies | |
| 2/2 | Fix indentation of just-tweaked section plus an off-by-one section.src/ | +60 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [Openvpn-devel] [PATCH 0/2] Fix CR prompt with --auth-user-pass + R from a file
There is a bug in the challenge/response code when the username & password is read from a file -- the response is never prompted for. This bug affects older versions, including 2.3.8. The following patchset applies to master, and uses a similar bool idiom as what has been added for user & pass.
I also added code to read the response out of the --auth-user-pass file if there is a 3rd line present. This is particularly useful for an 2FA setup where the response is unchanging (in my case it is always "push" for a Duo Push).
The master branch already supports treating an empty password in the file as indicating that the password should be prompted from the user (2.3.8 used to complain), so I also amended the manpage to mention that the password can be empty in addition to its line not being present. This allows me to use a file that contains user / empty-pass / "push" and have openvpn just prompt me for my password.
I've broken the patch up into 2 parts for clarity, since it re-indents a large section of code. The 2nd patch also fixes an off-by-one indentation that is in the same file. Feel free to merge the patches together, as you see fit.