Talk:Dante
From Botdom Wiki
This is the discussion page for Dante
Contents |
Suggestions for SVN version
- Include Dios
0.9a through 0.4 patch
To use this patch you need to replace the "getAuthToken" function in /system/classes/damn.php with the code below. The function can be found towards the bottom of the stated file.
/** *Get Token * *This function logs the bot into it's account and steals the cookie from the server. The cookie contains an Md5 hash, called an AuthToken. The dAmn server (chat.deviantart.com:3900) uses the AuthTokens for login not passwords. So the bot needs to grab the Authtoken before logging into the chat server. *@author SubjectX52873M <SubjectX52873M@gmail.com> *@author electricnet *@return mixed FALSE on errors, string( 32 ) on success *@version 0.4 */ function getAuthToken() { internalMessage( "Getting authtoken..." ); global $event,$config; $login = parse_ini_file( f( "config.ini" ) ); //This loads the $login $query = "username=" . $login['username'] . "&password=" . $login['password'] . "&reusetoken=1" . chr( 0 ); $data = "POST /users/login HTTP/1.1\n" . "Host: www.deviantart.com\n" . "User-Agent: " . BotUserAgent . "\n" . "Accept: text/html\n" . "Cookie: skipintro=1\n" . "Content-Type: application/x-www-form-urlencoded\n" . "Content-Length: " . strlen( $query ) . "\n\n" . $query; unset( $login ); //Remove $login to prevent modules from grabbing the password. $a = socket_create( AF_INET, SOCK_STREAM, getprotobyname( "tcp" ) ); @socket_connect( $a, "www.deviantart.com", 80 ); @socket_send( $a, $data, strlen( $data ), 0x0 ); $response = @socket_read( $a, 8192 ); if ( socket_last_error( $a ) ) { internalMessage( "WARNING Can't open socket for login. Check your internet connection." ); die; } @socket_clear_error( $a ); @socket_close( $a ); if( !empty( $response ) ) { $full1=explode("Set-Cookie: ",$response); $full1=explode(";",$full1[1]); $fullcookie=$full1[0].';'; $response = urldecode( $response ); if( stristr( $response, "Set-Cookie: " ) && stristr( $response, "authtoken" ) ) { $bits = explode( "userinfo=", $response ); $cookie = substr( $bits[1], 0, strpos( $bits[1], "; expir" ) ); $cookie = unserialize( $cookie ); if( !empty( $cookie['authtoken'] ) ){ internalMessage( "Authtoken: " . $cookie['authtoken'] ); //Need a authtoken event $event = "authtoken"; include f( "system/callables/event.php" ); $this->spoof($fullcookie); return $cookie['authtoken']; } else { internalMessage( "Oops, couldn't get the authtoken. You may need to find it yourself." ); $event = "authtoken-fail"; include f( "system/callables/event.php" ); return FALSE; } } else { internalMessage( "Oops, couldn't get the authtoken. You may need to find it yourself." ); $event = "authtoken-fail"; include f( "system/callables/event.php" ); return FALSE; } } else { internalMessage( "Oops, couldn't get the authtoken. You may need to find it yourself." ); $event = "authtoken-fail"; include f( "system/callables/event.php" ); return FALSE; } } function spoof($fullcookie){ #echo "COOKIE: $fullcookie \n"; $data = "GET /chat/Botdom HTTP/1.1\n" . "Host: chat.deviantart.com\n" . "User-Agent: ".BotUserAgent." \n" . "Referer: http://chat.deviantart.com/" . "Accept: text/html\n" . "Cookie: " . trim($fullcookie) . "\n\n"; $a = socket_create(AF_INET, SOCK_STREAM, getprotobyname("tcp")); socket_connect($a, "chat.deviantart.com", 80); socket_send($a, $data, strlen($data), 0x0); $response = socket_read($a, 8192); #echo ">HTTP\n" . $response . "\n"; // This is only for debugging; We don't really want to use the response for anything socket_close($a); }
Things that are not bugs
Before reporting bugs check that you are using the command properly.
- "Fatal error: Call to undefined function socket_create() in C:\Documents and Settings\Daverto\Desktop\Dante_0.8_01142007\main.php on line 98"
- This is caused by a improper setup of php. This is not a bug.
- Check the bot's php setup instructions in the manual.
- In Dante 0.9 this error should be caught before the bot starts up.
- Most situations of the bot getting disconnected.
- Check with The-Bot-Team before reporting.
- No Trivia, or other feature.
- Not a bug. Add that to suggestions.
Things that are bugs
Core Issues (Critical)
- Removing the google search module prevents commands from working
- Caused by a continue statement in the regex command parser.
- Fixed in Dante 0.10 (SVN/Trunk)
- Caused by a continue statement in the regex command parser.
Core Issues (Non-Critical)
- Bot messages are not consistent.
Module Issues
- Idler
- Due to the rebuilt core of Dante 0.9 the params function no longer exists.
- Idler Fix
- This is to fix the idler command in the games module. Just copy the php file in the zip to the system folder inside the bot's folder. This restores the params function to the bot.
- google on linux
notice
eh, i think we should put the bit about SubjectX etc being banned back in the title. After all, that *is* the reason and there's no reason to hide that. Infinity0 06:46, 26 September 2007 (PDT)
Development has been permanently halted. I have not worked on the bot since being banned and I would not be able to modify the bot without alot of work. I've decided to write a new bot in python which will appear in a few weeks if nothing happens to me. --SubjectX52873M 12:34, 6 January 2008 (PST)
Okay, something has happened. I don't have time for new bots. I will be fixing up Dante for a bug fix. I hope to release Dante 1.0 within a month after getting the bugs out. --SubjectX52873M 13:08, 18 January 2008 (PST)
Development of Dante has not been transfered to any new people. Only Nol888 and myself have access to the development repository on epochwolf.com. The respository is on my server and is freely maintained by myself for the community. New bots using Dante's source are welcome but anyone wishing to develop on the Dante project should contact me. I have not transfered the rights of the project.
(I am still the project owner and Nol888 is a developer on the project) Anyone wanting to work on Dante will need access to my repository. I can be reached at SubjectX52873M@gmail.com.
--SubjectX52873M 09:18, 11 August 2008 (PDT)
Well, as far as i know Subject is the sole programmer of Dante. So in my opinion it should stay they way it was unless otherwise stated by him, considering he's the one who made it... --Kyogo 20:51, 12 August 2008 (PDT)
- Psst. I've contacted Subject by email, and he has formally told me that the only developers currently of dante are himself and nol888 --Miksago 00:19, 13 August 2008 (PDT)
- Try reading the previous comments before posting your own. --SubjectX52873M 05:57, 13 August 2008 (PDT)

