saxo icon indicating copy to clipboard operation
saxo copied to clipboard

Allow joining password protected channels

Open rretzbach opened this issue 9 years ago • 5 comments

I have looked at the documentation and I don't see a way to configure a password for a password protected irc channel. So I'd like to see this enhancement in saxo.

According to RFC1459, 4.2.3.1 Channel modes you can set a password protected channel like:

/mode #mychannel +k mypassword

To solve this issue three things must be done imho: I. configure password protected channels, for example

[client]
    nick = saxo67301
    channels = ##saxo #test #mychannel|mypassword
    prefix = .

II. let saxo join a channel by passing the password, see Wiki IRC_Commands for the irc command. I think irc.py needs to be changed

III. update the documentation to show how the configuration is done, probably in config.md

Tell me what you think about this.

rretzbach avatar Mar 25 '15 16:03 rretzbach

This is a great RFE, but I'm not sure about the config syntax. Do you have any other suggestions? Will have to think about this.

sbp avatar Mar 28 '15 14:03 sbp

Are you unsure about the password being parsed correctly? Or do you not like the proposed delimiter characters?

I can also imagine the following simple config syntaxes:

[client]
nick = saxo67301
channels = ##saxo, #test, #mychannel mypassword
prefix = .

or

[client]
nick = saxo67301
channels = ##saxo #test #mychannel<mypassword>
prefix = .

If you choose different delimiters you get more variations.

Another solution would be to use a different file format like json which supports tree like struktures. Similar to an irssi config file.

rretzbach avatar Mar 29 '15 21:03 rretzbach

One problem with using |, <, or > as delimiters is that they are valid channel characters:

   Channels names are strings (beginning with a '&', '#', '+' or '!'
   character) of length up to fifty (50) characters.  Apart from the
   requirement that the first character is either '&', '#', '+' or '!',
   the only restriction on a channel name is that it SHALL NOT contain
   any spaces (' '), a control G (^G or ASCII 7), a comma (',').

RFC 2812, § 1.3

So only #mychannel,mypassword would work. Another possibility is:

[client]
nick = saxo67301
channels = ##saxo #test #mychannel
passwords = #mychannel mypassword
prefix = .

Using another parameter, passwords, and something a bit like an alist.

sbp avatar Mar 31 '15 10:03 sbp

Curious if anyone has made an update to support this feature? Still appears to be no way to allow a saxo bot so join a key/password protected IRC channel. Even with the 'join' command.

jeff-bollinger avatar Dec 11 '15 17:12 jeff-bollinger

Here is a patch that implement the channel,passwd.

I had to change the behavior within irc.py to use ":" quickly going trough the RFC, i think this is not needed, not intended for client irc code (not double checked). passwd channel access didn't worked with "JOIN: #channel password" but does with "JOIN #channel password". All seems to work happily with this patch for us.

saxo.channel.passwd.diff.txt

jfdive avatar Dec 17 '15 15:12 jfdive