collapse collapse
* User Info
 
 
Welcome, Guest. Please login or register.
* Search

* Board Stats
  • stats Total Members: 989
  • stats Total Posts: 18365
  • stats Total Topics: 2500
  • stats Total Categories: 7
  • stats Total Boards: 35
  • stats Most Online: 1144

Author Topic: AOChat: not expecting login (again)  (Read 20433 times)

0 Members and 1 Guest are viewing this topic.

Offline Zeephonz

  • BeBot User
  • **
  • Posts: 43
  • Karma: +0/-0
AOChat: not expecting login (again)
« on: June 26, 2008, 12:12:32 am »
I decided to move my org bot across from the Windows PC to a *nix box. The *nix box is running PHP v5.2.5 (cli version), MySQL and has Bebot 0.4.3 copied across to it.

Everything connects properly to the SQL database, a php -m shows BCMath etc loaded, but again I see that horrible message "AOChat: not expecting login" popping up.

Start up the Windows one, everything is fine, switch back, same error. I have looked at every thread on this here, tried all suggestions relevant to my versions, but to no avail.

What could possibly be causing this?
« Last Edit: June 26, 2008, 01:38:41 am by Zeephonz »

Offline Blueeagle

  • Omnipotent
  • BeBot Hero
  • ******
  • Posts: 323
  • Karma: +0/-0
Re: AOChat: not expecting login (again)
« Reply #1 on: June 26, 2008, 03:35:32 am »
The instant suspect is conf/Bot.conf

Not that, unlike windows, *nix filenames are case sensitive so bot.conf is not the same file as Bot.conf. If the file is all lower case it will never be loaded.

Also check the file permissions.

I will look at adding fatal errors when config files are not found or cannot be loaded, but for now you'll just have to double check the files manually.

Never mind that. That file is required so it should be fatal if not found.

Need to do a bit more research.

But please do double check the username and password that is in conf/Bot.conf

Also please include distro, kernel, architecture and build version of PHP.
« Last Edit: June 26, 2008, 04:14:10 am by Blueeagle »
The only problem that can't be solved by adding another wrapper is having too many wrappers.

Offline Temar

  • Contributor
  • *******
  • Posts: 1140
  • Karma: +0/-0
    • AoFiles
Re: AOChat: not expecting login (again)
« Reply #2 on: June 26, 2008, 04:41:07 am »
unless u are right but he uses multi bots but its loading the default file because of cant find argument.Bot.conf

Offline Zeephonz

  • BeBot User
  • **
  • Posts: 43
  • Karma: +0/-0
Re: AOChat: not expecting login (again)
« Reply #3 on: June 26, 2008, 05:55:51 am »
I run the bot from the directory it's installed in, and it's the only bot on this machine.

Here's the main load of information you are looking for...

Bebot 0.4.3 - installed
MySQL 5.0.51b

> php -v
PHP 5.2.4 (cli) (built: Aug 31 2007 23:57:08)
Copyright (c) 1997-2007 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2007 Zend Technologies

> php -m
[PHP Modules]
bcmath
bz2
calendar
ctype
curl
date
dbase
dom
exif
fbsql
filter
ftp
gd
gettext
hash
iconv
imap
json
ldap
libxml
mbstring
mcrypt
memcache
mhash
ming
mssql
mysql
mysqli
oci8
odbc
OpenBase Module
openssl
pcntl
pcre
pdf
PDO
pdo_mysql
PDO_OCI
pdo_pgsql
pdo_sqlite
pgsql
posix
Reflection
session
shmop
SimpleXML
snmp
soap
sockets
SPL
SQLite
standard
sysvmsg
sysvsem
sysvshm
tokenizer
wddx
xml
xmlreader
xmlrpc
xmlwriter
xsl
zip
zlib

[Zend Modules]

> Starting the bot gives...

_/_/_/      _/_/_/  _/_/_/      _/_/        _/_/   

         An Anarchy Online Chat Automaton         

             v.0.4.3 - PHP 5.2.4     

===================================================

Connected to MySQL

Botname [2008-06-26 03:36:46]  [CORE]  [LOAD]  Security.php
Botname [2008-06-26 03:36:46]  [SETTINGS]      [LOAD]  Loaded settings from database.
(all the otherstuff in between loads here cleanly)
Botname [2008-06-26 03:36:50]  [LOGIN] [STATUS]        Connecting
Botname [2008-06-26 03:36:51]  [LOGIN] [STATUS]        Authenticating
Botname [2008-06-26 03:37:15]  [LOGIN] [RESULT]        Error
Botname [2008-06-26 03:37:15]  [LOGIN] [STATUS]        Logging in
AOChat: not expecting login.

... then goes into startup loop, trying again.

Anything else you need?

Offline Blueeagle

  • Omnipotent
  • BeBot Hero
  • ******
  • Posts: 323
  • Karma: +0/-0
Re: AOChat: not expecting login (again)
« Reply #4 on: June 26, 2008, 08:56:24 am »
Botname [2008-06-26 03:36:50]  [LOGIN] [STATUS]        Connecting
Botname [2008-06-26 03:36:51]  [LOGIN] [STATUS]        Authenticating
Botname [2008-06-26 03:37:15]  [LOGIN] [RESULT]        Error
Botname [2008-06-26 03:37:15]  [LOGIN] [STATUS]        Logging in
AOChat: not expecting login.

... then goes into startup loop, trying again.

Anything else you need?

I need you to check the user name and password one more time. Also you need to check that the name of the player that the bot assumes is correct.
And if you still think the username/password/toon is right log in to that accout using your regular anarchy client.
And if it still fails after you've corrected the username/password/toon then I'll need a copy of your bot directory after you've removed the username and passwords from your Bot.conf and MySQL.conf files zipped up and sendt here so I can rule out that it's not infact a typo.

Also read this previous post
« Last Edit: June 26, 2008, 09:00:50 am by Blueeagle »
The only problem that can't be solved by adding another wrapper is having too many wrappers.

Offline Zeephonz

  • BeBot User
  • **
  • Posts: 43
  • Karma: +0/-0
Re: AOChat: not expecting login (again)
« Reply #5 on: June 26, 2008, 09:23:18 am »
Everything verified as per your request, here are the files...

As an update, this is a direct copy of my Windows bot, which works fine, the only difference being the clarification of the PHP binary in StartBot.php

Windows runs, I stop it, *nix version fails, and I can restart the Windows one again no problem.

I don't profess to being a *nix person, but followed the guidelines as per all documentation. Frustrating, but I'm sure you gods can sort it out ;)
« Last Edit: June 26, 2008, 09:40:08 am by Zeephonz »

Offline Temar

  • Contributor
  • *******
  • Posts: 1140
  • Karma: +0/-0
    • AoFiles
Re: AOChat: not expecting login (again)
« Reply #6 on: June 26, 2008, 01:44:41 pm »
looking at the log it seems to be the username / password
not the Char as the Error is before it tries that

Offline Slacklin

  • BeBot User
  • **
  • Posts: 52
  • Karma: +0/-0
  • My spoon is too big!
    • United Org Site
Re: AOChat: not expecting login (again)
« Reply #7 on: June 26, 2008, 08:41:20 pm »
One thing that got me when I used a linux system was the username is case sensitive. That might be another place to look.

Offline Zeephonz

  • BeBot User
  • **
  • Posts: 43
  • Karma: +0/-0
Re: AOChat: not expecting login (again)
« Reply #8 on: June 26, 2008, 10:51:55 pm »
One thing that got me when I used a linux system was the username is case sensitive. That might be another place to look.

Ya, I was reading earlier threads on that, and have tried a mix of all lowercase, all uppercase, first upper-rest lower etc. But that was consistent tries between all parts.

I'll try mixing up the case options with each one e.g name lower case, password mixed case etc, in case one is ok and it's failing on the other.

Is there any code that could be inserted into one of the PHP files that could copy the packet being sent to a file, or something like that, that could be analysed to see what is actually going out?
« Last Edit: June 26, 2008, 10:54:11 pm by Zeephonz »

Offline Slacklin

  • BeBot User
  • **
  • Posts: 52
  • Karma: +0/-0
  • My spoon is too big!
    • United Org Site
Re: AOChat: not expecting login (again)
« Reply #9 on: June 26, 2008, 11:57:58 pm »
Just do a simple output of what the variable is that is being sent, should be pretty easy to see it.

Offline Zeephonz

  • BeBot User
  • **
  • Posts: 43
  • Karma: +0/-0
Re: AOChat: not expecting login (again)
« Reply #10 on: June 27, 2008, 12:21:05 am »
Just do a simple output of what the variable is that is being sent, should be pretty easy to see it.

errr ummm.... someone wanna tell me how?

I'm no PHP coder kinda dude, more of a copy/paste kinda dude.  ;D



Offline Blueeagle

  • Omnipotent
  • BeBot Hero
  • ******
  • Posts: 323
  • Karma: +0/-0
Re: AOChat: not expecting login (again)
« Reply #11 on: June 27, 2008, 06:49:47 am »
Everything verified as per your request, here are the files...
Well I put my username and password in bot.conf and mysql.conf and it connected as it should.

What may be an issue is character encoding if you use some special characters. Try removing the lines in the conf files and type them up from scratch.

It may (in theory) be that your php and bcmath is broken. If that is the case re-building php and bcmath from source is an option.

Which distribution are you working with?

Edit: Have you tried all lower-case username?
Edit: When I pourpously enter the wrong username I get the error message you got.
The only problem that can't be solved by adding another wrapper is having too many wrappers.

Offline Khalem

  • BeBot Founder
  • Administrator
  • ********
  • Posts: 1169
  • Karma: +0/-0
    • http://www.ancarim.com
Re: AOChat: not expecting login (again)
« Reply #12 on: June 27, 2008, 10:33:30 am »
If his PHP is generating invalid keys to send to the server, he will be getting the same error as you since his password will be wrong on account of PHP messing it up.

I'll see if i can get the time to add some debug strings to the AOChat library later.
BeBot Founder and Fixer Kingpin

Offline Blueeagle

  • Omnipotent
  • BeBot Hero
  • ******
  • Posts: 323
  • Karma: +0/-0
Re: AOChat: not expecting login (again)
« Reply #13 on: June 27, 2008, 01:30:30 pm »
Which architecture is the bot running on? It could be caused by 64-bit intigers not overflowing like 32-bit ones. (ie. they will not).
The only problem that can't be solved by adding another wrapper is having too many wrappers.

Offline Zeephonz

  • BeBot User
  • **
  • Posts: 43
  • Karma: +0/-0
Re: AOChat: not expecting login (again)
« Reply #14 on: June 28, 2008, 11:21:19 am »
OK, the architecture is 32-bit, but it's a Mac G4 (PPC).

Both the Darwin flavour (Mac OSX 10.4.11), and the Debian distro I just installed, come up with the same error.


 

* Recent Posts
0.8.x updates for AO by bitnykk
[June 23, 2024, 03:19:47 pm ]


0.8.x updates for AoC by bitnykk
[June 23, 2024, 03:19:44 pm ]


[AoC] special char for items module by bitnykk
[February 09, 2024, 09:41:18 pm ]


BeBot still alive & kicking ! by bitnykk
[December 17, 2023, 12:58:44 am ]


Bebot and Rasberry by bitnykk
[November 29, 2023, 11:04:14 pm ]

* Who's Online
  • Dot Guests: 202
  • Dot Hidden: 0
  • Dot Users: 0

There aren't any users online.
* Forum Staff
bitnykk admin bitnykk
Administrator
Khalem admin Khalem
Administrator
WeZoN gmod WeZoN
Global Moderator
SimplePortal 2.3.7 © 2008-2024, SimplePortal