- Posts: 937
- Thank you received: 17
IP logging
- JTP
- Topic Author
- Offline
- Platinum Member
-
Less
More
2 years 1 week ago - 2 years 1 week ago #9873
by JTP
IP logging was created by JTP
I have a problem with someone that many times a day connect, but never login or create a char...how could I add a log showing the IP of someone that connects but doesn’t log on ?
all that I see in game is:
[ Losing descriptor without char. ]
all that I see in game is:
[ Losing descriptor without char. ]
Last edit: 2 years 1 week ago by JTP.
Please Log in or Create an account to join the conversation.
- thomas
-
- Offline
- Administrator
-
Less
More
- Posts: 816
- Thank you received: 159
2 years 1 week ago #9875
by thomas
Replied by thomas on topic IP logging
The log message comes from here: github.com/tbamud/tbamud/blob/master/src/comm.c#L2092
You can alter it slightly:At least I think that should work.
You can alter it slightly:
- mudlog(CMP, LVL_IMMORT, TRUE, "Losing descriptor without char.");
+ mudlog(CMP, LVL_IMMORT, TRUE, "Losing descriptor without char. Source IP: %s", d->host);
The following user(s) said Thank You: mr514
Please Log in or Create an account to join the conversation.
- JTP
- Topic Author
- Offline
- Platinum Member
-
Less
More
- Posts: 937
- Thank you received: 17
2 years 16 hours ago #9876
by JTP
Replied by JTP on topic IP logging
Ok it shows the DNS. Any chance that it could revolve the IP number instead ?
Please Log in or Create an account to join the conversation.
- thomas
-
- Offline
- Administrator
-
Less
More
- Posts: 816
- Thank you received: 159
2 years 14 hours ago #9877
by thomas
Replied by thomas on topic IP logging
Not directly. Currently, the code finds the hostname for the connecting host and only that is stored in the descriptor. The code that does this is here:
github.com/tbamud/tbamud/blob/5305783e1b...342/src/comm.c#L1516
So you could rewrite to support both, or change the lookup to only use numeric address and ignore the hostname. But it will need coding.
github.com/tbamud/tbamud/blob/5305783e1b...342/src/comm.c#L1516
So you could rewrite to support both, or change the lookup to only use numeric address and ignore the hostname. But it will need coding.
Please Log in or Create an account to join the conversation.
Time to create page: 0.098 seconds