Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Desktop connection is not automatically disconnected upon idle timeout #5820

Closed
ghost opened this issue Feb 18, 2024 · 12 comments · Fixed by #5838
Closed

Desktop connection is not automatically disconnected upon idle timeout #5820

ghost opened this issue Feb 18, 2024 · 12 comments · Fixed by #5838
Assignees
Labels

Comments

@ghost
Copy link

ghost commented Feb 18, 2024

Describe the bug
with "userSessionIdleTimeout" in the Config file, when using the Desktop to connect to another device, the browser is prompting a confirmation request for leaving or staying in the site.
This is true to the Desktop and not the RDP as I didn't test it on RDP.

To Reproduce
Steps to reproduce the behavior:

  1. Add "userSessionIdleTimeout to the Config file
  2. Connect to a device using the Desktop
  3. Leave the connect until idle
  4. See prompt from the browser

Expected behavior
Disconnecting the Desktop connection upon idle timeout

Screenshots
If applicable, add screenshots to help explain your problem.

Server Software (please complete the following information):

  • OS: Linux Mint
  • Version: 1.1.21
  • Node: v20.11.1

Client Device (please complete the following information):

  • Device: Laptop and Tower
  • OS: Window 11 and Linux Mint 21.3
  • Network: Local and Remote
  • Browser: Firefox (Tested as well in Edge)

Remote Device (please complete the following information):

  • Device: Laptop and Tower
  • OS:Window 11 and Linux Mint 21.3
  • Network: Local and Remote
  • Current Core Version (if known): Nov 21 2022, 2089848313 (Linux) Dec 9 2022, 1508625241 (Windows)

Additional context
Add any other context about the problem here.

Your config.json file

{
  "$schema": "https://raw.githubusercontent.com/Ylianst/MeshCentral/master/meshcentral-config-schema.json",
"__comment1__": "This is a simple configuration file, all values and sections that start with underscore (_) are ignored. Edit a section and remove the _ in front of the name. Refer to the user's guide for details.",
  "__comment2__": "See node_modules/meshcentral/sample-config-advanced.json for a more advanced example.",
  "settings": {
    "cert": "91.65.173.11"
  },
  "domains": {
    "": {
	"userSessionIdleTimeout": 15
    }
  }
}

@ghost ghost added the bug label Feb 18, 2024
@si458
Copy link
Collaborator

si458 commented Feb 20, 2024

ok the code just simply diverts you to the logout page if ur time is up, which is no use IF you are connected to a remote device!
https://github.com/Ylianst/MeshCentral/blob/master/views/default.handlebars#L2333
so we need to disconnect ur session first, then redirect you...
looking into it 👍

@si458
Copy link
Collaborator

si458 commented Feb 20, 2024

have you tried restarting the meshcentral and also closing ur browser and reopening it then trying again?
seems to work here ok?

@ghost
Copy link
Author

ghost commented Feb 20, 2024

I've tried reseting the mesh itself and also restarting the machine and still not working for me.

@si458
Copy link
Collaborator

si458 commented Feb 20, 2024

i will look at it again tomorrow, but all seems to work fine here which is weird?

@si458
Copy link
Collaborator

si458 commented Feb 21, 2024

i still cant get it to show the message, it closed the desktop as it should and then diverts to the logout page.
can u do a screenrecording of it happening please?
set the idle timeout to something like 2mins

@ghost
Copy link
Author

ghost commented Feb 21, 2024

i still cant get it to show the message, it closed the desktop as it should and then diverts to the logout page. can u do a screenrecording of it happening please? set the idle timeout to something like 2mins

Adding the clip. It's in German so sorry in advance,

Desktop.mp4

@si458
Copy link
Collaborator

si458 commented Feb 21, 2024

idletimeout
nope just cant replicate it! grrr... what browser/OS are you using?

@ghost
Copy link
Author

ghost commented Feb 21, 2024

FireFox 64bit on Linux Mint. The same happens in Edge on a Windows machine.
I have also a WIndows version of the server.
I could test it as well if you want but later today after work.

@si458
Copy link
Collaborator

si458 commented Feb 21, 2024

ive just through, whats your full config.json? (as the config doesnt look complete above)
do you have minify: true by any chance? if thats set you need to set it to false !
because the minify doesnt happen on the fly, it happens when we release updates!

@ghost
Copy link
Author

ghost commented Feb 21, 2024

Can we do it agin later today in the evening?
It doesn't work for some reason and I can't understand what I'm doing wrong

@si458
Copy link
Collaborator

si458 commented Feb 21, 2024

sure, my email on my github profile, or leave a comment on my dontation page and i can email you

@si458
Copy link
Collaborator

si458 commented Feb 21, 2024

just updating this issue for future for others
if you update the default.handlebars file, you must run an extractall and translateall for the translations to also apply it!
the commands will convert the patched english file into all the languages!

  1. cd node_modules/meshcentral/translations
  2. node translate.js extractall
  3. node translate.js translateall
  4. refresh web browser!

@si458 si458 closed this as completed Feb 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant