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

License validation process relies on a system time instead of a server #413

Closed
3 tasks done
DBotThePony opened this issue Feb 27, 2023 · 6 comments
Closed
3 tasks done

Comments

@DBotThePony
Copy link

DBotThePony commented Feb 27, 2023

Please answer the following questions for yourself before submitting an issue.

  • I am running the latest version
  • I checked the documentation and found no answer
  • I checked to make sure that this issue has not already been filed

AdGuard VPN version

2.0.784

Operating mode

VPN

Environment

- OS: Windows 10.0.19044
- Other network-level software: AdGuard

Issue Details

Steps to reproduce:

  1. Obtain VPN subscription from AdGuard website
  2. Attempt to use the subscription within 'narrow' expiration period due to UTC timezones (any UTC+2 and up should work)
  3. Experience weird program behavior (pressing Connect will display 'Connecting...' and then 'Disconnected' without any clues what happened) while being unable to connect to VPN

Expected Behavior

Being able to connect to VPN until current subscription end

Actual Behavior

Unable to connect, service logs contain next lines:

WARNING, AdGuardVpnSvc.exe, Logger, 18, 27.02.2023 9:45:51.366, Cannot complete the operation due to license status 'VALID' and/or time expire `27.02.2023 5:18:23`
INFO, AdGuardVpnSvc.exe, Logger, 18, 27.02.2023 9:45:51.367, Auth configuration is not specified: False, False, True
WARNING, AdGuardVpnSvc.exe, Logger, 18, 27.02.2023 9:45:51.368, Cannot update vpn token and credential
INFO, AdGuardVpnSvc.exe, Logger, 18, 27.02.2023 9:45:51.369, Auth configuration is not specified: False, False, True
WARNING, AdGuardVpnSvc.exe, Logger, 18, 27.02.2023 9:45:51.369, Cannot connect to VPN, auth configuration is not specified

On machine with UTC+7 timezone (license expires by 5:18:23 UTC+7 or UTC+0?; AdGuard website says license is still valid)

Screenshots

Screenshot 1:

rSklJJjQgk

Additional Information

This issue is not present on Adguard for Android, Android app successfully connects to VPN servers despite having the same timezone settings.

This also prevents connecting to VPN even if you made new subscription (different payment method), but the latter not being active due to current still being valid (not expired)

@DBotThePony
Copy link
Author

Switching timezone to UTC+1 AND restarting AdGuard VPN service does allow me to connect to VPN servers normally.

@adguard-bot adguard-bot assigned mozartinio and unassigned Aydinv13 Feb 28, 2023
@mozartinio
Copy link
Contributor

@DBotThePony Hi!
Does it reproduce on the new VPN version 2.0.789.0 (2.0.3) ?

@DBotThePony
Copy link
Author

DBotThePony commented Mar 6, 2023

At time of writing the issue report, client was on latest, so unless you fixed the bug in 2.0.789.0 it should still be reproducible.

I am unable reproduce it now either way because my (yearly) subscription got updated.

EDIT:

as i expected, turning clock back (to older subscription, or to time frame between old and new subscriptions) produce no meaningful result, it doesn't connect either way (because of TLS certificate validation error).

@mozartinio
Copy link
Contributor

mozartinio commented Mar 24, 2023

@DBotThePony
Sorry for the long answer
I need more information about your issue
So as i understand you bought subscription and in the end of your yearly subscription you changed time zone and after that VPN cant be in status "connected". And if you change your time zone back the problem still reproduced?
Am i right?
Also can you please leave you email address so i could check your subscriprion

@DBotThePony
Copy link
Author

Sorry for the long answer
I need more information about your issue
So as i understand you bought subscription and in the end of your yearly subscription you changed time zone and after that VPN cant be in status "connected". And if you change your time zone back the problem still reproduced?
Am i right?

The root cause of issue is basically desktop client checking whenever license has experied using local timezone, while server sends timestamp without timezone. So, for example, if license expires at 05:00 UTC+0, and your PC' local time is 07:00 UTC+7, VPN client will (locally) incorrectly assume license has experied. If you change your PC' clock to 04:00 UTC+7 or 04:00 UTC+0, VPN client will successfully connect.

Also can you please leave you email address so i could check your subscriprion

roboderpy at gmail dot com

@VladisLoveZh VladisLoveZh added the Bug Something isn't working label May 2, 2023
@adguard-bot adguard-bot changed the title Cannot complete the operation due to license status 'VALID' Срок действия подписки подсчитывается локально, а не на сервере. AG VPN May 3, 2023
@adguard-bot adguard-bot changed the title Срок действия подписки подсчитывается локально, а не на сервере. AG VPN License validation process relies on a local time instead of a server May 3, 2023
@adguard-bot adguard-bot changed the title License validation process relies on a local time instead of a server License validation process relies on a system time instead of a server May 3, 2023
@adbuker
Copy link

adbuker commented May 29, 2023

@DBotThePony , сould you please update to the latest nightly and check whether the issue remains

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants