Question

How could i add sasl authentication on my Lua 5.1 IRC Bot? Right now it sends a message to Nickserv to identify.

Is there any way at all to add SASL authentication? I use the lua socket module to connect to IRC. The complete source can be found at https://github.com/wolfy1339/Wolfybot

Was it helpful?

Solution

To fully support SASL you must first support CAP IRC extensions, and then SASL AUTH PLAIN.

You can find documentation on these via the IRCv3 specifications: http://ircv3.net/specs/extensions/sasl-3.1.html

CAP LS is used to determine if SASL is supported by the network, then once you have enabled it via CAP REQ, you can send AUTH PLAIN with your base64 encoded username and password.

IMPORTANT SECURITY NOTE: Make sure you also use SSL, as AUTH PLAIN offers NO security and BLOWFISH etc are not gauranteed to be portable to different services packages!

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top