CDM Script
 

News:

29 December 2022 - PtokaX 0.5.3.0 (20th anniversary edition) released...
11 April 2017 - PtokaX 0.5.2.2 released...
8 April 2015 Anti child and anti pedo pr0n scripts are not allowed anymore on this board!
28 September 2015 - PtokaX 0.5.2.1 for Windows 10 IoT released...
3 September 2015 - PtokaX 0.5.2.1 released...
16 August 2015 - PtokaX 0.5.2.0 released...
1 August 2015 - Crowdfunding for ADC protocol support in PtokaX ended. Clearly nobody want ADC support...
30 June 2015 - PtokaX 0.5.1.0 released...
30 April 2015 Crowdfunding for ADC protocol support in PtokaX
26 April 2015 New support hub!
20 February 2015 - PtokaX 0.5.0.3 released...
13 April 2014 - PtokaX 0.5.0.2 released...
23 March 2014 - PtokaX testing version 0.5.0.1 build 454 is available.
04 March 2014 - PtokaX.org sites were temporary down because of DDOS attacks and issues with hosting service provider.

Main Menu

CDM Script

Started by MrI, 13 February, 2004, 21:01:28

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

MrI

Hi
Scripters got some input from a great developer.This are some tips for scripters from the Author of BCDC++ on a script for a Client Detection Mod (Script)
I will paste all our chat here

[19:37:32] as I said, I'm uninterested in making a CDM
[19:37:38] ok
[19:37:43] to some extent, one can create one using lua scripts
[19:37:52] since they can listen in on connections, etc
[19:37:53] certainly a passive one
[19:38:07] (wrong supports, mismatched pk/version number)
[19:38:27] will suggest to scripters
[19:38:34] good idea
[19:39:05] okay. now, if you want additional script stuff to make that easier/more powerful, I'll listen more...
[19:39:22] I'm more amenable to that sort of thing
[19:39:40] then go for it
[19:39:56] if u can writea script
[19:40:15] I'm not going ot write it...
[19:40:17] to
[19:40:23] again, uninterested
[19:40:31] then give me ideas
[19:40:41] if there's stuff lua's incapable of doing that would be help, I may add them though
[19:40:55] i will post them in forum
[19:40:58] well, okay
[19:41:16] BCDC++'s Lua support is akin mostly to a network filter in front of DC++.
[19:41:39] One can monitor all incoming and outgoing connections, both client-client and client-hub.
[19:42:14] can i quote ur name?
[19:42:15] As demonstrated by the example script, one can know which users are ops, are on which hubs, iterate over them, etcetera, because it receives the same DC commands DC++ later sees.
[19:42:18] Sure.
[19:42:21] k
[19:42:55] Further, for incoming connections, one can prevent DC++ from further processing commands; I'm unsure how useful that is to a CDM. That capability doesn't (yet) exist for outbound stuff, though is a possibility I guess.
[19:43:15] So, what one can do now:
[19:43:33] (1) Compare version tag in MyINFO with the one in the Pk.
[19:43:53] (2) Compare the supports sent with the version.
[19:44:17] (3) Look for things like the Pk= or lack thereof in the Client-client connection for NMDC-ness (IIRC that's one of the ++k CDM things)
[19:45:03] Further, the "background hub scan" will deal with queuing users on the hubs and creating null connections to them.
[19:45:15] So that you'll end up seeing those C-C connections.
[19:45:55] ok
[19:46:03] If not, you can trigger one yourself by manually sending a $ConnectToMe to the other user via the hub (since you can send arbitrary commands to the hub)
[19:46:18] or revconnecttome, of course
[19:46:44] Any passive detection technique will work given the current Lua script support, I'm fairly sure.
[19:47:36] shit u really are good
[19:47:44] u know ur stuff
[19:48:10] that it?
[19:48:20] i can post it now?
[19:48:23] Also thinks like verifying self-consistent lock/pk, for example
[19:48:33] k
[19:48:39] NMDC 2.x has some fairly obvious restrictions in how it generates them.
[19:49:13] But, well, these CDM techniques are all relatively well known, and again, any purely passive ones will certainly work in BCDC++ already.
[19:49:30] So I shouldn't really need to catalogue them all here.
[19:49:33] ok
[19:50:23] Once you get them, you can do various things - send a $Kick automatically, send a PM to an opchat, etcetera.
[19:50:30] k
[19:50:39] Oh, one major limitation - you can't do much with filelists at the moment.
[19:51:37] You can kind of hack around it by finding the filelist directory, relying on an external bzip2 program, using Lua's operating system facilities to run it, and then loading the resulint text into lua, but shouldn't
[19:51:43] because when lua is running, it will block lots of things
[19:51:57] Anything one does in lua should return control to BCDC++ quickly.
[19:52:21] Don't sit in Lua and wait for anything, or run lengthy decompression, etcetera.
[19:52:46] can i say u r author of BCDC++ or not
[19:52:53] Sure.
If some Scripter gets some idea to do this would be great
Thnx

SMF spam blocked by CleanTalk