This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

Eggdrop Blow Encryption

Old posts that have not been replied to for several years.
Locked
B
BiLL
Halfop
Posts: 78
Joined: Wed Sep 26, 2001 8:00 pm
Location: Germany

Eggdrop Blow Encryption

Post by BiLL »

Hi,

is it possible to encrypt EVERYTHING what an eggdrop say's in a special chan? For mIRC I've an addon - BlowCrypt - there I can set a special key for every chan and it get's encrypter and auto decrypted. I need this in TCL for eggdrop - where I can an special key for the chan too.

Is there such script out?
User avatar
user
 
Posts: 1452
Joined: Tue Mar 18, 2003 9:58 pm
Location: Norway

Post by user »

The short answer is "no".
The long answer is...

Eggdrop has no clue about what channel you're sending messages to, so you'd have to rewrite the internal output commands to parse everything sent to the server.

This sounds like a bad idea to me. I get the feeling you're after encrypting messages sent by a script, and that would be much easier. Just change every line that makes some output to your channel to call your encryption/output proc. I bet your decryption is based on some keyword at the start of every message to determine that it's an encrypted string, so that would make it easy for the eggdrop to pick up these lines and decrypt them for you.

Now there's only one problem left; the actual encrypt/decrypt function. If it's compatible with eggdrop's own blowfish encryption (even using the same salts), no problem. If not: start reading the source of that addon (it's open source, right?)
B
BiLL
Halfop
Posts: 78
Joined: Wed Sep 26, 2001 8:00 pm
Location: Germany

Post by BiLL »

I just saw an eggdrop with blow encryption.

How is that possible?

I searched around the web but didn't find any public script ;-(.
User avatar
caesar
Mint Rubber
Posts: 3778
Joined: Sun Oct 14, 2001 8:00 pm
Location: Mint Factory

Post by caesar »

Actualy is possible to encrypt EVERYTHING what the eggdrop says in a special channel by using the encrypt to encrypt and decrypt to.. doh! :)
Once the game is over, the king and the pawn go back in the same box.
B
BiLL
Halfop
Posts: 78
Joined: Wed Sep 26, 2001 8:00 pm
Location: Germany

Post by BiLL »

Ok great, got it working right now.

But the problem is it doesnt decrypt my input. So when i try to do !hello it wont respond cause I am sending with blowcrypt. How can I make the bot that it will decrypt my message and will execute the proc for !hello ?

Thanks.
User avatar
user
 
Posts: 1452
Joined: Tue Mar 18, 2003 9:58 pm
Location: Norway

Post by user »

use a 'pubm' bind (with the channel name included in the mask to avoid having to decrypt EVERY public message recieved by the bot) and call the other procs after decrypting the message and extracting the command part.
User avatar
caesar
Mint Rubber
Posts: 3778
Joined: Sun Oct 14, 2001 8:00 pm
Location: Mint Factory

Post by caesar »

Why do you want to encrypt the commands? Sound silly to me..
Once the game is over, the king and the pawn go back in the same box.
B
BiLL
Halfop
Posts: 78
Joined: Wed Sep 26, 2001 8:00 pm
Location: Germany

Post by BiLL »

No,

you got me wrong.

When someone sends the public command with blowfish encyption THEN the bot WONT reply, cause it couldnt decrypt the input (so it couldnt read it correctly). I will try that way which "user" told me this evening. I think that will do it :).
B
BiLL
Halfop
Posts: 78
Joined: Wed Sep 26, 2001 8:00 pm
Location: Germany

Post by BiLL »

Damn, it is not that easy as I thought.

set key "asdf"
bind pubm - "#mychan *" decryptall

proc decryptall { nick uhost handle chan arg } {
global key
set arg [decrypt $key "$arg"]
putserv "PRIVMSG $chan :arg = $arg"
return 0
}

It won't decrypt the input correctly.
If I sent a TEXT WITH BLOWFISH (same key!) the bot will not decrypt the text correctly. Why? I am using same keys!

The interesting thing is that I CAN read the encrypted messages of the bot with my blowfish script for mIRC. So I thought eggdrop/mircblowfish got the same salts. But it doesn't look like that now in the decrypt function. Maybe I am doing something wrong ? Can anyone help me? PLEASE !
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

just a thought, try spliting the $arg or specifying first word ?
B
BiLL
Halfop
Posts: 78
Joined: Wed Sep 26, 2001 8:00 pm
Location: Germany

Post by BiLL »

set text [decrypt $blowkey [string range $arg 4 9999]]

that worked - thanks all!
Locked