Log connections

All new MODs released in our MOD Database will be announced in here. All support for released MODs needs to take place in the Customisations Database.
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

NOTICE: This forum is only for the announcement of new releases and/or updates of MODs. Any MOD support should be obtained through the Customisations Database in the support area designated for each MOD.

A direct link to support for each MOD is in the first post of the respective topic.
Locked
MAD9393
Registered User
Posts: 2
Joined: Fri Sep 05, 2008 11:44 pm

Re: Log connections

Post by MAD9393 »

:D Installed and working very well. :D
DeezerQ
Registered User
Posts: 19
Joined: Fri Aug 29, 2008 7:32 pm

Re: Log connections

Post by DeezerQ »

I was pretty darned careful with my edits. But I've double checked to make sure that only Admins have access to the ACP. One thing that I have noticed is this:

If a user logs in and doesn't have it, it has "Connected successfully (Autologged)"
But if it doesn't contain that "(Autologged)" behind the "Connected successfully" then it shows, and always within the same minute, I might add, even for myself "Connected successfully to ACP" including for myself, even if I don't connect to the ACP until later, and my intentional connection to the ACP shows up again when I intentionally log in to the ACP. It's alsmost as if connecting manually triggers this entry and language, giving a false impression that they're connecting to the ACP. None of these people have permission to the ACP, I've double checked that. It only shows up if they don't show up as being connected (autologged).
updown wrote:
DeezerQ wrote:that says "Connected successfully to ACP" ... I'm wondering exactly what that means.
That's an easy one: That means, that either they are connecting to your ACP, or you made some mistakes with your edits. So one way or the other, you should worry 8-)
Elglobo
Former Team Member
Posts: 838
Joined: Mon May 22, 2006 5:16 pm
Location: France
Name: Mickaël SALFATI
Contact:

Re: Log connections

Post by Elglobo »

DeezerQ,

To be honest, I don't undersand well this part of your message below. Maybe with several screens, that would be more clear ?
If a user logs in and doesn't have it, it has "Connected successfully (Autologged)"
But if it doesn't contain that "(Autologged)" behind the "Connected successfully" then it shows, and always within the same minute, I might add, even for myself "Connected successfully to ACP" including for myself, even if I don't connect to the ACP until later, and my intentional connection to the ACP shows up again when I intentionally log in to the ACP. It's almost as if connecting manually triggers this entry and language, giving a false impression that they're connecting to the ACP. None of these people have permission to the ACP, I've double checked that. It only shows up if they don't show up as being connected (autologged).
Now, It's good to know that I didn't touch in my MOD the treatment done by phpBB3 for admin connections.
Indeed, in default phpBB3 the log record for admin connection is created in includes/functions.php :

Code: Select all

		if ($admin)
		{
			if ($result['status'] == LOGIN_SUCCESS)
			{
				add_log('admin', 'LOG_ADMIN_AUTH_SUCCESS');
			}
In my MOD, I only change the log type of this record, in order to display the log in my log connection panel and not in the log admin panel by default. I also add add a condition if logs to acp are disable, so we get:

Code: Select all

		if ($admin)
		{
			if ($result['status'] == LOGIN_SUCCESS)
			{
//-- mod : log connections --------------------------------------------------------
//-- delete
/*-MOD
				add_log('admin', 'LOG_ADMIN_AUTH_SUCCESS');
MOD-*/
//-- add
				if (!$config['lc_acp_disable'])
				{
					add_log('connections', 'LOG_ADMIN_AUTH_SUCCESS');
				}
			}
//-- end : log connections --------------------------------------------------------
Finally, if you have a log "Connected successfully to ACP", either:
  • you have really a successful connection to your ACP.
  • you are a mistake in your edit. (Check your functions.php file)
  • you discover an issue in phpBB3.
In all cases, that would be great if you could explain me your example.

Keep me informed ;)
Last edited by Elglobo on Mon Sep 08, 2008 8:41 am, edited 1 time in total.
phpBB-Services.com: L'hébergement et l'assistance de votre forum phpBB en toute tranquillité.
MAD9393
Registered User
Posts: 2
Joined: Fri Sep 05, 2008 11:44 pm

Re: Log connections

Post by MAD9393 »

The only thing I would like to see added to Log connections is GUESTS that view the Forums.
DeezerQ
Registered User
Posts: 19
Joined: Fri Aug 29, 2008 7:32 pm

Re: Log connections

Post by DeezerQ »

I think I've found the problem. In the mod file, the language you quoted wasn't there, instead under the includes/functions.php this coding is contained (4th mod in the install package I was working with, named "Version 1.0.2":

Code: Select all

		if ($admin)
		{
			if ($result['status'] == LOGIN_SUCCESS)
			{
//-- mod : log connections --------------------------------------------------------
//-- delete
/*-MOD
				add_log('admin', 'LOG_ADMIN_AUTH_SUCCESS');
MOD-*/
//-- add
				if (!$config['lc_acp_disable'])
				{
					add_log('connections', 'LOG_ADMIN_AUTH_SUCCESS');
				}
			}
//-- end : log connections --------------------------------------------------------
There is a minor difference on line 13 of the mod in the install file and the code you pasted in your post:

From install package

Code: Select all

					add_log('connections', 'LOG_ADMIN_AUTH_SUCCESS');
From your post

Code: Select all

               add_log('connections', 'LOG_ADMIN_AUTH_SUCCESS'[/l);
Notice that at the end of the line from the code in your post there is a [/l contained but in the install file code that's missing. I'm not sure if that's where the problem lies, but there is a minor difference.

Maybe I had somehow gotten my hands on a slightly older version, but this isn't the same as the coding you quoted in your post previous to this one. I've changed it to the code you provided and uploaded it again, so I'll let you know if it's working better now. I guess, then, the only other option is to have you take a look at it yourself, but I've searched for the changes and all appear to have been made properly.

Here is a copy of the screenshot, which I admit I didn't do a very good job of explaining, but then again, the expression, "A picture is worth a thousand words" will always be true, no matter what.

Image

Okay, well, I used the code that you provided, uploaded the file and couldn't access my board anymore, so I replaced it with the old file, and it works just fine again. I'm not sure what the problem is.
User avatar
ej311
Registered User
Posts: 29
Joined: Mon Aug 04, 2008 4:53 pm

Re: Log connections

Post by ej311 »

Posted in the wrong forum. It's been a long night =]
Elglobo
Former Team Member
Posts: 838
Joined: Mon May 22, 2006 5:16 pm
Location: France
Name: Mickaël SALFATI
Contact:

Re: Log connections

Post by Elglobo »

MAD9393 wrote:The only thing I would like to see added to Log connections is GUESTS that view the Forums.
Hi MAD9393,

For information, this option is planed in the 2.x.x version, always in development.

DeezerQ,

The part [/l was an oversight in my post above. The code in the install file, is definitely correct.
Now, to advance on your problem, you can send me by PM, an archive zip of your complete forum root, in order to check your files.

@+ ;)
phpBB-Services.com: L'hébergement et l'assistance de votre forum phpBB en toute tranquillité.
Elglobo
Former Team Member
Posts: 838
Joined: Mon May 22, 2006 5:16 pm
Location: France
Name: Mickaël SALFATI
Contact:

Re: Log connections

Post by Elglobo »

DeezerQ,

You did a mistake in includes/functions.php, and that's your problem ;)
In this file, search:

Code: Select all

		// We also break the operation on the first non-success login - it could be argued that the user already knows		if ($admin)
Replace by:

Code: Select all

		// We also break the operation on the first non-success login - it could be argued that the user already knows
		if ($admin)
Be carefull the next time to put the code as the MOD ask it, i.e on a new line :)
In your file, the condition (if $admin) was commented because on the same line than the previous comment.

@+ ;)
phpBB-Services.com: L'hébergement et l'assistance de votre forum phpBB en toute tranquillité.
DeezerQ
Registered User
Posts: 19
Joined: Fri Aug 29, 2008 7:32 pm

Re: Log connections

Post by DeezerQ »

Okay, thank you! I thought I was being careful, but obviously not careful enough!
joebart72
Registered User
Posts: 743
Joined: Thu Feb 01, 2007 5:54 am

Re: Log connections

Post by joebart72 »

Hi Elglobo (I tried to find your mod on the french board but I must be blind... :lol: But it's good for my English ^^) : Do your mod log all guest Ips too or only people who try to connect on the board ? If my english is so bad, I'll tell you in French with PM ^^.

Thanks ;)
I learn English with phpbb.com :)
User avatar
muggins
Registered User
Posts: 1183
Joined: Fri Feb 22, 2008 5:12 pm
Location: Texas
Name: Donovan
Contact:

Re: Log connections

Post by muggins »

Only connections or attempts to connect.
Muggins
Elglobo
Former Team Member
Posts: 838
Joined: Mon May 22, 2006 5:16 pm
Location: France
Name: Mickaël SALFATI
Contact:

Re: Log connections

Post by Elglobo »

Do your mod log all guest Ips too or only people who try to connect on the board ? If my english is so bad, I'll tell you in French with PM ^^.
HI joebart ;)

Sorry for the delay of response. For information, this function will be available in the 2.x.x version which is in development ;)
phpBB-Services.com: L'hébergement et l'assistance de votre forum phpBB en toute tranquillité.
User avatar
muggins
Registered User
Posts: 1183
Joined: Fri Feb 22, 2008 5:12 pm
Location: Texas
Name: Donovan
Contact:

Re: Log connections

Post by muggins »

Nice, thanks!

I host my own server, so I can do "tail -f -s 3 -n 7 /var/log/apache2/access.log" in a terminal, but for remotely hosted boards, this would be great!

How much load will this place on very busy boards?
Muggins
Elglobo
Former Team Member
Posts: 838
Joined: Mon May 22, 2006 5:16 pm
Location: France
Name: Mickaël SALFATI
Contact:

Re: Log connections

Post by Elglobo »

Hi muggins,

Apache log is a good thing but not integrated to phpBB, and sometimes it's very complicated to follow users on him forum with this tool ....

This will work as the phpBB2 version and more (There will be a panel to enable/disable logging of anonymous on index, viewtopic, viewforum, viewprofile .... )

I have some ideas to manage/optimize logs. I also planed to give to the users the ability to export automatically on excel (not CSV, but really an excel file) logs.

See you later ;)
phpBB-Services.com: L'hébergement et l'assistance de votre forum phpBB en toute tranquillité.
ranman22
Registered User
Posts: 3
Joined: Sat Nov 01, 2008 8:13 pm

Re: Log connections

Post by ranman22 »

Elglobo wrote: Sorry for the delay of response. For information, this function will be available in the 2.x.x version which is in development ;)
Any idea when this might be coming along? I started to implement the 1.0.2 version, but noticed some discrepancies (well, I think they are discrepancies) -- there were a few different places that said "Add BEFORE" instead of "Add AFTER" (specifically in auth_db.php) that didn't make sense to me. Were these typos or am I just being dense? :D Probably the latter.

Looking forward to being able to implement this mod...

-Randy
Locked

Return to “[3.0.x] MOD Database Releases”