PtokaX forum

Development Section => LUA & PtokaX-Scripting-Interface => Topic started by: lazyj189 on 24 November, 2003, 08:02:52

Title: AXDC, a web based chat client
Post by: lazyj189 on 24 November, 2003, 08:02:52
Anyone ever heard of it?  I tried to use it and it almost works.

this is what I get when it tries to log into my hub.

[22:49] anything (xx.xx.xx.xx) > $Version 1,0091|
[22:49] anything (xx.xx.xx.xx) > $GetNickList|
[22:49] anything (xx.xx.xx.xx) > $MyINFO $ALL anything <++ V:0.304,M:A,H:1/0/0,S:3>$ $DSL$$214242212131$|
[22:49] anything (xx.xx.xx.xx) > $WebUser|
[22:49] x User removed: anything (Socket 2492)

and of course, it isnt connected, but it has to have something to do with the $webuser that is sent.  Just looks like it might be kinda cool if it actually connected.
Title:
Post by: pHaTTy on 24 November, 2003, 08:10:35
yep ive had it for about a year, and it works for me m8 ;)
Title:
Post by: lazyj189 on 24 November, 2003, 08:12:23
ok then what might I be doing wrong since it wont connect to my hub?  I'm running 15.18 debug

It does successfully connect to a NMDC hub, but I run ptokax.  grrrrrrr
Title:
Post by: lazyj189 on 24 November, 2003, 08:19:18
     classid="clsid:2FD9D1E8-D96B-4E9D-B699-36CDFD708390"
     codebase="AXDC.cab#version=0,2,1,11"







align=center
     hspace=0
     vspace=0
>
Title:
Post by: HaArD on 24 November, 2003, 19:20:00
Try adding this script in PtokaX...

function DataArrival(user, data)
if strfind(data, "$WebUser") then return 1 end
End
I think that'll get you past the command that PtokaX doesn't recognize and therefore it Kicks the AXDC client.

HaArD
Title:
Post by: xokas on 24 November, 2003, 19:40:09
where can i get that AXDC? and what is AXDC?
Title:
Post by: [ES]latinmusic on 24 November, 2003, 20:45:55
Question: This web client is ptokax compatible? i need one if possible, what about?.
Title:
Post by: xokas on 25 November, 2003, 00:40:02
Latin do ya know the purpose of AXDC?
Title:
Post by: plop on 25 November, 2003, 02:52:06
QuoteOriginally posted by xokas
Latin do ya know the purpose of AXDC?
it shows a website wich connects 2 your hub so ppl not running dc can also join the chat.

btw on sf you can find a full dc version build in php, but it needs linux 2 run.

plop
Title:
Post by: xokas on 25 November, 2003, 02:59:59
tkhx a lot for the hint plop :)
Title:
Post by: DarkElf on 25 November, 2003, 05:09:02
QuoteOriginally posted by HaArD
Try adding this script in PtokaX...

function DataArrival(user, data)
if strfind(data, "$WebUser") then return 1 end
End
I think that'll get you past the command that PtokaX doesn't recognize and therefore it Kicks the AXDC client.

HaArD

don't work...
Syntax error: `end' expected (to close `function' at line 1);
  last token read: `' at line 4 in string "function DataArrival(user, data)
..."
Title:
Post by: lazyj189 on 25 November, 2003, 05:25:34
function DataArrival(user, data)
if strfind(data, "$WebUser") then
return 1
end
end



this works
Title:
Post by: DarkElf on 25 November, 2003, 05:59:26

-------------Allow AXDC webchat users made by DarkElf 25/11/2003

botname = "{Web}Chat"
bot_email = "blabla"
bot_speed = "GanjaLan(ThC)"
bot_descr = "Allow WebChat users"
bot_share_size = 40.01 * 1024 *1024 *1024
my_info_string = "$MyINFO $ALL "..botname.." "..bot_descr.."$ $"..bot_speed..strchar( 1 ).."$"..bot_email

function Main()
frmHub:RegBot(botname)
my_info_string = "$MyINFO $ALL "..botname.." "..bot_descr.."$ $"..bot_speed..strchar( 1 ).."$"..bot_email..
"$"..bot_share_size.."$"
end

function NewUserConnected(curUser)
curUser:SendData( my_info_string )
end

function OpConnected(curUser)
curUser:SendData( my_info_string )
end

function DataArrival(user, data)
if strfind(data, "$WebUser") then return 1
  end
end

this too :P

bye
Title:
Post by: zef on 06 December, 2003, 17:21:09
QuoteOriginally posted by DarkElf
QuoteOriginally posted by HaArD
Try adding this script in PtokaX...

function DataArrival(user, data)
if strfind(data, "$WebUser") then return 1 end
End
I think that'll get you past the command that PtokaX doesn't recognize and therefore it Kicks the AXDC client.

HaArD

don't work...
Syntax error: `end' expected (to close `function' at line 1);
  last token read: `' at line 4 in string "function DataArrival(user, data)
..."
that was my error too, but LUA is case sensitive ;)
"End" and "end" isn't the same thing

thks for the tips in AXDC
Title:
Post by: Pacman on 07 December, 2003, 01:53:12
Quotebtw on sf you can find a full dc version build in php, but it needs linux 2 run.

this works fine on windows too (xp anyway),
aslong as the hub has darkelfs script running, good job :)

it can be downloaded >>here<< (http://sourceforge.net/project/showfiles.php?group_id=93941&release_id=195361)
Title:
Post by: plop on 07 December, 2003, 03:39:05
QuoteOriginally posted by Pacman
Quotebtw on sf you can find a full dc version build in php, but it needs linux 2 run.

this works fine on windows too (xp anyway),
aslong as the hub has darkelfs script running, good job :)

it can be downloaded >>here<< (http://sourceforge.net/project/showfiles.php?group_id=93941&release_id=195361)
no i mean this (http://sourceforge.net/projects/phpdc/) 1.
php frontend for dctc.

plop
Title:
Post by: Pacman on 07 December, 2003, 03:56:56
oh, my bad. hehehe

//Pacman
Title:
Post by: Odin on 18 February, 2004, 23:24:11
Found some info here (http://dcplusplus.sourceforge.net/forum/viewtopic.php?t=1342&highlight=axdc&sid=3d1eeed7832e6a3be0ba74bdc3d68052) :

by ptaczec
QuoteAny DC client should follows the DC protocol. AXDC violates the protocol in initial handshake. It's not sending any $Version and $MyINFO is optional. Note, that the handshake sequence MUST be followed exactly when connecting to PtokaX hubs (and should be exact also in case of other hub softs to prevent security holes).
Also new command $WebUser should be first sent in $Supports command to find if the hub supports it or not!

This is valid handshake sequence:
H - Hub
C - Client

C connects to H
H sends $Lock
C answers with $Key
H send $HubName
C sends $ValidateNick
H answers with $Hello in case of normal user or $GetPass in case of registered one
C sends $MyPass (if registered)
C sends $Version
C sends $GetNickList
C sends $MyINFO

after (and only after) the $MyINFO is sent the client is fully logged in and can place search requests or chat or whatever he/she wants. This sequence MUST be followed exactly (or in modified version to fit the $Supports extension - depends on $Lock).


AXDC client sequence (client data only):

Client connected
127.0.0.1:1275 > $Key r?????2?2?2?2??????r?r?r??????2?2?2
127.0.0.1:1275 > $ValidateNick testuser
127.0.0.1:1275 > $MyINFO $ALL testuser Test$ $DSL$$2142422$
127.0.0.1:1275 > $WebUser
127.0.0.1:1275 > $GetNickList


Std DC++ client sequence (client data only):

127.0.0.1:1276 > $Key ??b???b???b???b???b???b??
127.0.0.1:1276 > $ValidateNick testuser
127.0.0.1:1276 > $Version 1,0091
127.0.0.1:1276 > $GetNickList
127.0.0.1:1276 > $MyINFO $ALL testuser <++ V:0.24,M:P,H:1/0/1,S:3>$ $LAN(T1)$$0$


Std NMDC client sequence (client data only):

Client connected
127.0.0.1:1285 > $Key 'A?C?#A?C???C?A#?C???A?A#?A?AcA?C?#A?C???C?A#
127.0.0.1:1285 > $ValidateNick testuser
127.0.0.1:1285 > $Version 1,0091
127.0.0.1:1285 > $GetNickList
127.0.0.1:1285 > $MyINFO $ALL testuser $ $Cable$$3916283862$

Can you see the difference? :)
Anyway good work ;) If you modify it to fit the protocol then it will be fine. And remember, the MyINFO is esential and can not be optional!
Also the AXDC should NOT fake the share counter! Make it fully functional! Or soon we will have hubs full of webusers with no share :/
Because PtokaX is actually the only windows-based hub sw publicly available with strict DC protocol checking I also recommend to test the AXDC against PtokaX :)

source code is avilable here (http://sourceforge.net/project/showfiles.php?group_id=93941)

Looks like the developer has abandoned this project. I wish someone would sort that log in sequence.