Welcome, Guest. Please login or register.

Login with username, password and session length

 
Advanced search

10 989 Posts in 6 364 Topics- by 1 216 Members - Latest Member: santini862

16 January 2021, 09:00
Select Language English | Russian ru | German
Main PageIRC Client KVIrc forumKVIrc discussionKVIrc scriptingHelp with window.setCryptEngine
Pages: [1]
Print
Author Topic: Help with window.setCryptEngine  (Read 12101 times)
0 Members and 1 Guest are viewing this topic.
oldhouse
Новичок
*

Репутация: 0
Posts: 5


View Profile
« on: 9 February 2010, 17:57 »

Hi.
I am trying to write a script that as soon as I join a channel, a crypt and decrypt key is set for that channel.

Right now, I have added these lines at "OnInvite" event:
Code:

if ($0 == "botnick")
 {
   mode mynick +h
   join #mychannel mypassword
 }

In this way, when I get an invite from bot, I automatically join channel protected by password.
How should I proceed to use the command window.setCryptEngine, setting Mircryption passwordencrypt passworddecrypt?

Could this work in OnMeJoin?

Code:
if ($chan.name == "#mychannel")
{
window.setCryptEngine Mircryption chankeytoencrypt chankeytodecrypt
}


If not, could you post a sample how to make it work with window variable?
Thanks
« Last Edit: 9 February 2010, 22:05 by oldhouse » Logged
ambossarm
Постоялец
***

Репутация: 11
Gender: Male
Posts: 148



View Profile
« Reply #1 on: 10 February 2010, 04:13 »

mynick should be $me

if the setCrypt command is right, it should work, you may try it just on the command line and if it works there, it should also work

I suggest using window.setCryptEngine $window Micryption ...
and perhaps $target instead of $chan.name, but they should do the same thing for your purpose, $target works also at queries
Logged
oldhouse
Новичок
*

Репутация: 0
Posts: 5


View Profile
« Reply #2 on: 10 February 2010, 13:02 »

Thanks for correction.
First part works fine, but second doesn't cause window.setCryptEngine requires a target window, therefore I get this error:

[KVS] Warning: Window with ID 'Mircryption' doesn't exist.

I have just tried window.setCryptEngine $window Micrcryption in script tester, but I get this error:

Warning: Current window is not a channel.

Have to try on real join.
« Last Edit: 10 February 2010, 13:04 by oldhouse » Logged
ambossarm
Постоялец
***

Репутация: 11
Gender: Male
Posts: 148



View Profile
« Reply #3 on: 10 February 2010, 14:24 »

you tried it on a query or a server context?
In a channel window it works for me
Quote
/window.setCryptEngine $window Mircryption ABCDEF

but the Key has to be in Hex, what is ugly, but I found nothing else
Logged
oldhouse
Новичок
*

Репутация: 0
Posts: 5


View Profile
« Reply #4 on: 10 February 2010, 14:37 »

Thanks, using command with / works fine when executed in channel window. I hope it will work the same with correct target $window when called with OnMeJoin event.

BTW, if anyone is interested, you can use this site to convert txt into hex, so that you have right key to use in script:

hxxp://nickciske.com/tools/hex.php

Remember to remove last 00 bytes otherwise your key will be wrong.
Logged
ambossarm
Постоялец
***

Репутация: 11
Gender: Male
Posts: 148



View Profile
« Reply #5 on: 13 February 2010, 23:41 »

He did not tell me why, but
Quote
<CtrlAltCa> ambossarm: /echo $asciiToHex("Hello!")
So you do not have to use webpages Wink
Logged
ninest123
Ветеран
*****

Репутация: 0
Posts: 1 382


View Profile Email
« Reply #6 on: 25 June 2019, 10:29 »

kate spade outlet sale
uggs outlet
nike outlet store
canada goose jackets
coach outlet store online
coach outlet online
fitflops
pandora charms sale clearance
durant shoes
stone island hoodie
adidas store
coach factory outlet
polo ralph lauren outlet
dolce & gabbana sunglasses
michael kors outlet online
costa sunglasses sale
ralph lauren outlet
cheap jordans free shipping
air max plus
coach outlet store online
michael kors outlet clearance
phillies jerseys
cardinals jerseys
kyrie 2
canada goose outlet
coach factorty outlet store
coach factory outlet online
coach outlet online
nhl jerseys
yeti
michael kors outlet clearance
coach factory outlet
pandora charms
coach outlet online
nike free run
canada goose coats
kate spade outlet online
rolex replica watches for sale
michael kors bags
louboutin outlet
louis vuitton outlet online
pandora jewelry
converse shoes
mbt shoes
marc jacobs handbags
nike outlet store online
coach outlet clearance
air jordan retro
fitflops outlet
valentino
coach factory outlet online
ralph lauren polo
kate spade outlet online
jaguars jersey
north face outlet
birkenstock sandals
ugg boots
air jordan 3
louboutin outlet
adidas nmd r1
north face jackets
ed hardy
off-white clothing
ferragamo outlet
uggs outlet
david yurman
coach factory outlet
browns jerseys
fitflop sale
coach outlet store
uggs canada
polo ralph lauren outlet online
coach factory outlet online
coach outlet clearance
michael kors outlet store
minnesota vikings jersey
canada goose coats
instyler ionic styler
pandora jewelry canada
lacoste polo shirts
toms outlet store
moncler outlet online
pandora outlet
coach factory outlet online
ravens jerseys
fjallraven kanken
kate spade handbags
mlb jerseys
pandora jewelry outlet
nike blazer
cubs jerseys
ronaldo jerseys
fitflops sale clearance
north face outlet online
uggs
ecco outlet
kobe shoes
coach handbags
coach outlet online
patriots jerseys
air max shoes
air max
coach outlet online
adidas yeezy boost
toms
pandora charms sale
ed hardy outlet
gucci bags
christian louboutin shoes
cowboys jerseys
gucci outlet online
san diego chargers jerseys
christian louboutin sale
coach factory outlet online
nike shoes
michael kors outlet clearance
cheap jordan shoes
moncler jackets
maui jim sunglasses
yeezy shoes
pandora charms
jets jersey
true religion jeans
coach outlet
coach outlet
air jordan shoes
adidas sneakers
coach factorty outlet store
bape hoodie
juicy couture
yolo
Logged
Pages: [1]
Print
Jump to:  

Theme orange-lt created by panic