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

Brave crashes after linking desktop with existing VPN credentials and also fails with Failed to write the VPN config error #28940

Closed
MadhaviSeelam opened this issue Mar 7, 2023 · 8 comments · Fixed by brave/brave-core#17917

Comments

@MadhaviSeelam
Copy link

MadhaviSeelam commented Mar 7, 2023

Description

This issue specifically relates to clicking the link Already purchased VPN in onboarding/Buy modal after logging into desktop 2 with existing prod VPN credentials. In this case, after successfully logging, I didn't click Refresh Brave VPN button, instead clicked VPN button => Already purchased VPN link in the Buy modal. When I toggle On from Disconnected to Connected, it failed with Failed to write the VPN config error. Tried to toggle On again, Brave Crashed.

Steps to Reproduce

  1. Install 1.49.118
  2. launch Brave
  3. enable brave://flags/#brave-vpn
  4. login to desktop 2 with already purchased Brave prod VPN credentials
  5. click on VPN button next to hamburger menu
  6. click Already purchased VPN link
  7. toggle On from Disconnected to Connected in the VPN panel
  8. Got Failed to write the VPN config error
  9. toggle On again

Actual result:

Brave crashed
Crash ID: fbe80600-5aad-b509-0000-000000000000

[ 0 ] RasEntryToPhonebookEntry
[ 1 ] RasSetEntryPropertiesW
[ 2 ] brave_vpn::internal::CreateEntry(std::Cr::basic_string<wchar_t,std::Cr::char_traits<wchar_t>,std::Cr::allocator<wchar_t> > const &,std::Cr::basic_string<wchar_t,std::Cr::char_traits<wchar_t>,std::Cr::allocator<wchar_t> > const &,std::Cr::basic_string<wchar_t,std::Cr::char_traits<wchar_t>,std::Cr::allocator<wchar_t> > const &,std::Cr::basic_string<wchar_t,std::Cr::char_traits<wchar_t>,std::Cr::allocator<wchar_t> > const &) ( utils.cc:368 )
2023-03-07_09h45_25.mp4

Expected result:

Brave VPN should connect successfully without any crashes

Reproduces how often:

Easily

Brave version (brave://version info)

Brave | 1.49.118 Chromium: 111.0.5563.50 (Official Build) (64-bit)
-- | --
Revision | 39f3dfc5023fe60997adc4f6cf5439cfa3e6968a-refs/branch-heads/5563@{#903}
OS | Windows 11 Version 22H2 (Build 22621.1265)

Version/Channel Information:

  • Can you reproduce this issue with the current release? Yes
  • Can you reproduce this issue with the beta channel? N/A
  • Can you reproduce this issue with the nightly channel? N/A

Other Additional Information:

  • Does the issue resolve itself when disabling Brave Shields?
  • Does the issue resolve itself when disabling Brave Rewards?
  • Is the issue reproducible on the latest version of Chrome?

Miscellaneous Information:

@bsclifton @mattmcalister
@kjozwiak
Copy link
Member

Basically ran into the same crash that @MadhaviSeelam mentioned above using the following build(s):

Brave | 1.49.120 Chromium: 111.0.5563.64 (Official Build) (64-bit)
-- | --
Revision | c710e93d5b63b7095afe8c2c17df34408078439d-refs/branch-heads/5563@{#995}
OS | Windows 11 Version 22H2 (Build 22621.1344)
  • Purchased VPN on iOS with a brand new Apple ID that was created during the release call to make sure linking as working
  • once we were live, I ensured that I was added into CrossPlatformVPNStudy:Enabled using CrossPlatformVPNStudy:Enabled
  • clicked on the VPN icon and selected/clicked on Already purchased VPN?
  • used the same email that I used to register on the iOS and successfully linked the subscription from iOS -> Desktop
  • clicked on Germany and switched the toggle to enable the VPN (received permission error)
  • attempted to enable it again once more and the browser crashes with the same crash stack as the above

Crashes:

  • ab520600-c5e7-be09-0000-000000000000
  • a9520600-c5e7-be09-0000-000000000000

Crash Stack:

[ 0 ] RasEntryToPhonebookEntry
[ 1 ] RasSetEntryPropertiesW
[ 2 ] brave_vpn::internal::CreateEntry(std::Cr::basic_string<wchar_t,std::Cr::char_traits<wchar_t>,std::Cr::allocator<wchar_t> > const &,std::Cr::basic_string<wchar_t,std::Cr::char_traits<wchar_t>,std::Cr::allocator<wchar_t> > const &,std::Cr::basic_string<wchar_t,std::Cr::char_traits<wchar_t>,std::Cr::allocator<wchar_t> > const &,std::Cr::basic_string<wchar_t,std::Cr::char_traits<wchar_t>,std::Cr::allocator<wchar_t> > const &) ( utils.cc:368 )

@MadhaviSeelam
Copy link
Author

Reproduced the issue as few users seeing the support can't connect to any server without an error. Encountered Failed to write the VPN config error when switching between servers.

https://bravesoftware.slack.com/archives/C0141L60REG/p1679076522144569?thread_ts=1679074949.315209&cid=C0141L60REG

Brave | 1.49.120 Chromium: 111.0.5563.64 (Official Build) (64-bit)
-- | --
Revision | c710e93d5b63b7095afe8c2c17df34408078439d-refs/branch-heads/5563@{#995}
OS | Windows 11 Version 22H2 (Build 22621.1413)
  • New profile
  • Logged in to Brave VPN with prod VPN credentials
  • clicked Refresh VPN button
  • Enabled VPN
  • Switched the region from default US(West) to Candada
  • Failed to write the VPN config` error is shown
  • Tried to connect again and connected successfully
ex ex
image image

@bsclifton @mattmcalister
cc: @stephendonner

@bsclifton bsclifton self-assigned this Apr 4, 2023
@brave-builds brave-builds added this to the 1.52.x - Nightly milestone Apr 5, 2023
kjozwiak pushed a commit to brave/brave-core that referenced this issue Apr 5, 2023
kjozwiak pushed a commit to brave/brave-core that referenced this issue Apr 5, 2023
@kjozwiak
Copy link
Member

kjozwiak commented Apr 5, 2023

Going to add the release-notes/include label as we might have had some users experience the crash. I believe @bsclifton mentioned there was ~16 or so that appeared via BackTrace. It's possible that these all could have been from internally within Brave. @bsclifton @rebron @LaurenWags thoughts re: adding this into the notes? Either way works for me.

@kjozwiak
Copy link
Member

kjozwiak commented Apr 5, 2023

The above requires 1.50.114 or higher for 1.50.x verification 👍

@LaurenWags
Copy link
Member

Changed to release-notes/exclude per discussion with @kjozwiak @rebron

@MadhaviSeelam
Copy link
Author

Verification PASSED using

Brave | 1.50.114 Chromium: 112.0.5615.49 (Official Build) (64-bit)
-- | --
Revision | bd2a7bcb881c11e8cfe3078709382934e3916914-refs/branch-heads/5615@{#936}
OS | Windows 11 Version 22H2 (Build 22621.1413)

Verified using original STR #28940 (comment)

Confirmed Brave didn't crash after linking desktop with existing VPN credentials and no Failed to write the vpn config error shown when VPN enabled.

image

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