aMule Forum
English => en_Bugs => Topic started by: bk on March 15, 2008, 12:39:43 AM
-
hi there,
i run amuled with amuleweb on a server with two NICs. if i leave ECAddress blank, amuleweb listens on both of the two interfaces. that is, also on the outbound one. this is bad ;-). if i specifiy ECAddress, the remote gui is restricted to this address, but not amuleweb: it simply seems to listen nowhere. not even localhost. so i consider this a bug...
ah well, and i'm using this on a linux box. happens with 2.1.3 and 'SVN Sun Mar 9'...
-
just had a quick look at the sources:
it seems the webserver doesn't read in the ECAddress cfg value anywhere, it just listens everywhere.
the webserver seems to be initialised in CWSThread::Entry() with wxIPV4address.AnyAddress(), so it listens on 0.0.0.0.
fine so far.
the problem now is that amuled only listens on ECAddress, but it seems amuleweb wants to connect to localhost. furthermore, there is an option --host in the manpage, but it's not in the code for the webserver (as of mar 9 svn)
for connecting to the core, it uses CaMuleExternalConnector class, calling SendRecvMsg_v2(), which in turn calls SendRecvPacket().
phh, this is getting complicated... it sends a CECPacket, okay...
but now i'm stuck. where is the ip address of the external connection specified?
-
yeah, well nowhere. thats the problem.
i now figured out that amuleweb uses CaMuleExternalConnector and its member m_host is not set to ECAddress but localhost:
src/ExternalConnector.cpp:552
m_host = wxT("localhost");
shouldn't it be like in CaMuleExternalConnector::LoadConfigFile() :
m_host = m_configFile->Read(wxT("/EC/Host"), wxEmptyString);
or something?