On 08/17/2012 10:17 AM, Brett Smith wrote:
On 08/15/2012 10:20 AM, Alexander Barton wrote:
I'm not sure if "just make the buffer bigger" is the right approach: on the one hand, ngIRCd only needs the password while registering the client in the network, and lots of clients not even send any.
And by looking at the code I wonder why we save the password in the CLIENT structure at all: I don't think that a local daemon ever gets a password from a remote client!?
So I think the best would be to move the password file into the CONN structure, and probably make it dynamic using malloc() when needed …
My boss has given me the green light to spend some time on this, so hopefully I'll have a patch for you soon—later next week, if things go well.
I've done this. My work is at https://gitorious.org/~bretts/ngircd-irc-daemon/bretts-ngircd/commits/move-connection-password. If it'd be more convenient for me to provide it as a single patch or whatever else, just let me know. I also apologize in advance for my rusty and unstylish C. :) But at least it works correctly with the basic tests I've been running on password support for our new server. If this isn't quite right, though, please don't hesitate to let me know.
Thanks again,