Hi hackers, A short status update, as this thread has been quiet since September.
v3 [1] is two patches: - 0001 fixes a gap in how libpq clears a password read from the password file. passwordFromFile() does strdup() on the rest of the line and then de-escapes the password in place, so the tail of an escaped password, and any fields after it, are left in the allocation past the terminator, out of reach of the explicit_bzero(p, strlen(p)) in pqReleaseConnHosts(). It is +21/-9 in fe-connect.c and does not depend on the new API. - 0002 adds PQpassfileLookup(), a thin public wrapper around that same lookup. A client that connects through a tunnel or a proxy can use it to find the password for the real host and port, instead of carrying its own .pgpass parser. Yuriy reviewed the API patch and Denis the whole series. Neither has open comments, and the entry has been Ready for Committer since September 30 [2]. v3 still applies on master (d5fb939, offsets only) and cfbot is green, so I have not posted a rebase. Is there anything I can do to make this easier to pick up? If the API needs more discussion, 0001 can go in on its own, and I can move it to a separate thread if that helps. Michael, I added you in Cc because you reworked the error handling in passwordFromFile() last year (861af926103). [1] https://postgr.es/m/[email protected] [2] https://commitfest.postgresql.org/patch/7261/ Thanks, Diego
