Can we exclude an IP address range from the auto logout so that it does not trigger when a user is logged? For example if a user is logged in from the office then the auto logout does not trigger but if logged in from home then it does trigger. I read there are some developer hooks that can be used but there does not seem to be much documentation. Thanks.

Comments

Sohal Khatwani created an issue. See original summary.

ajits’s picture

Component: Documentation » Code
Category: Support request » Feature request

This could be a good feature to be added to the module. I would be happy to review if someone creates a patch for the same.

sohal khatwani’s picture

Hi @AjitS. That's good to hear. We were actually looking for some guidance on writing this or perhaps engage someone to do the work for us? Is this something you would consider writing and committing to the module after review?

klepzers’s picture

Hello!

Is it necessary for Drupal 7 or Drupal 8?
I might make feature like this for D8 version - add a list of Whitelisted IP addresses, which do not use auto-logout feature.

sohal khatwani’s picture

Hi. I think it’s beneficial to both. However need it for Drupal 7. Like your is for adding a list of whitelisted IP address.

klepzers’s picture

I have working solution for D8 already (I just haven't created an issue here for 8.x), maybe I will make for D7 also.

sohal khatwani’s picture

That’s great. Please let me know if we can help with testing or review.

klepzers’s picture

Here you go!

sohal khatwani’s picture

Thanks @klepzers. We will try this out.

klepzers’s picture

Status: Active » Needs review

Status: Needs review » Needs work

The last submitted patch, 8: autologout-prevent-by-whitelisted-ipaddresses-2769219.patch, failed testing. View results
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.

sohal khatwani’s picture

Hi @klepzers. Not sure this patch is working for D7. Can you confirm if this applies to autologout 7.x-4.5. Thanks.

deaom’s picture

Status: Needs work » Needs review
StatusFileSize
new3.28 KB

This patch seems to apply but with the p1 option. But there is an error in the patch that is why the test has an error and patch not working. It's the wrong array key used in the validation function.
Here is the corrected patch which applies with the p1 option and does not log out the IPs entered as far as I tested it.
Wrong file attached...

deaom’s picture

StatusFileSize
new3.29 KB

The correct file.

strozx’s picture

Applied the patch and it works as described. Thanks DeaOm!

strozx’s picture

Status: Needs review » Reviewed & tested by the community

  • boshtian committed bd4701d on 7.x-4.x authored by klepzers
    Issue #3081421 by DeaOm, klepzers, strozx: Disable autologout based on...
boshtian’s picture

Status: Reviewed & tested by the community » Fixed

  • boshtian committed 5e4ab34 on 7.x-4.x
    Issue #3081421 by boshtian: typo fix from initial commit on issue
    

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.