-
Notifications
You must be signed in to change notification settings - Fork 71
Open
Description
Describe the bug
Batch Explorer doesn't work in closed networks even if configured proxy settings. Because the proxy settings are broken due to a MSAL bug. The MSAL bug is not fixed in v2.x, 3.x, v5.x too. However, the MSAL bug can work around by code change of Batch Explorer.
- 👉🪲 proxyUrl implementation is broken (and here is a two-line fix) #8024
- https://github.com/AzureAD/microsoft-authentication-library-for-js/blob/431d989f7abe8a31027d1673f09a066f668a64a2/lib/msal-node/src/network/HttpClient.ts#L170
To Reproduce
Steps to reproduce the behavior:
- Prepare a server/PC that running Windows such as Windows 11, Windows Server 2025 Datacenter, etc.
- Connect that machine to a closed network. That machine can access to the internet via a proxy.
- Configure Windows proxy settings from Settings - Network & internet - Proxy - Use a proxy server.
- Install the Batch Explorer on that Windows machine.
- Launch the Batch Explorer.
- Open Edit - Configure Proxy from the menu of the Batch Explorer.
- Configure the proxy settings and click Save button. The Batch Explorer will relaunch automatically.
- e.g. Url:
http://10.3.1.4, Port:3128
- e.g. Url:
- Enable Use system browser for authentication and click Sign in to Azure.
- The system browser such as Microsoft Edge will launch automatically.
- Sign in to Azure on the system browser. After sign in completed, show
Successfully logged in to Batch Explorer. You may close this window.on the system browser. - However, the Batch Explorer window is no change. It's shows still Sign in to Azure. You cannot retrieve your Batch account information. You cannot access your Batch accounts via Batch Explorer.
Expected behavior
Batch Explorer does work in closed network with proxy settings.
Screenshots
N/A
Logs:
app.log.2026-03-23
{"0":"Uncaught (in promise): {\"errorCode\":\"unknown_error\",\"errorMessage\":\"Error(s): Not Available - Timestamp: Not Available - Description: An unknown error occured.\\nHttp status code: NaN\\nHttp status message: Unknown\\nHeaders: {} - Correlation ID: Not Available - Trace ID: Not Available\",\"subError\":\"\",\"name\":\"ServerError\",\"correlationId\":\"1b1f77b6-3309-46d2-9d9a-a4fedd022b35\"}","level":"error","message":"[BL] Uncaught exception:","timestamp":"2026-03-23T06:26:09.693Z"}
client.log.2026-03-23
{"_actionHandler":null,"_aliases":[],"_allowExcessArguments":true,"_allowUnknownOption":true,"_args":[],"_combineFlagAndOptionalValue":true,"_defaultCommandName":null,"_description":"","_enablePositionalOptions":false,"_events":{},"_eventsCount":5,"_executableFile":null,"_executableHandler":false,"_exitCallback":null,"_hasHelpOption":true,"_helpCommandDescription":"display help for command","_helpCommandName":"help","_helpCommandnameAndArgs":"help [command]","_helpConfiguration":{},"_helpDescription":"display help for command","_helpFlags":"-h, --help","_helpLongFlag":"--help","_helpShortFlag":"-h","_hidden":false,"_lifeCycleHooks":{},"_name":"BatchExplorer","_optionValueSources":{},"_optionValues":{},"_outputConfiguration":{},"_passThroughOptions":false,"_scriptPath":"C:\\Program Files\\BatchExplorer\\BatchExplorer.exe","_showHelpAfterError":false,"_showSuggestionAfterError":false,"_storeOptionsAsProperties":false,"_version":"2.23.0-stable.1210","_versionOptionName":"version","args":[],"commands":[],"level":"info","message":"Program arguments","options":[{"description":"output the version number","flags":"-V, --version","hidden":false,"long":"--version","mandatory":false,"negate":false,"optional":false,"required":false,"short":"-V","variadic":false},{"description":"Disables autoupdate for one instance of opening up the application","flags":"--disable-auto-update","hidden":false,"long":"--disable-auto-update","mandatory":false,"negate":false,"optional":false,"required":false,"variadic":false},{"description":"If the application was just updated","flags":"--updated","hidden":false,"long":"--updated","mandatory":false,"negate":false,"optional":false,"required":false,"variadic":false},{"description":"Change the user data directory. Used for tests","flags":"--user-data-dir <path>","hidden":false,"long":"--user-data-dir","mandatory":false,"negate":false,"optional":false,"required":true,"variadic":false},{"description":"Ignore https certificate errors","flags":"--ignore-certificate-errors","hidden":false,"long":"--ignore-certificate-errors","mandatory":false,"negate":false,"optional":false,"required":false,"variadic":false}],"parent":null,"processedArgs":[],"program":{"_actionHandler":null,"_aliases":[],"_allowExcessArguments":true,"_allowUnknownOption":true,"_args":[],"_combineFlagAndOptionalValue":true,"_defaultCommandName":null,"_description":"","_enablePositionalOptions":false,"_events":{},"_eventsCount":5,"_executableFile":null,"_executableHandler":false,"_exitCallback":null,"_hasHelpOption":true,"_helpCommandDescription":"display help for command","_helpCommandName":"help","_helpCommandnameAndArgs":"help [command]","_helpConfiguration":{},"_helpDescription":"display help for command","_helpFlags":"-h, --help","_helpLongFlag":"--help","_helpShortFlag":"-h","_hidden":false,"_lifeCycleHooks":{},"_name":"BatchExplorer","_optionValueSources":{},"_optionValues":{},"_outputConfiguration":{},"_passThroughOptions":false,"_scriptPath":"C:\\Program Files\\BatchExplorer\\BatchExplorer.exe","_showHelpAfterError":false,"_showSuggestionAfterError":false,"_storeOptionsAsProperties":false,"_version":"2.23.0-stable.1210","_versionOptionName":"version","args":[],"commands":[],"options":[{"description":"output the version number","flags":"-V, --version","hidden":false,"long":"--version","mandatory":false,"negate":false,"optional":false,"required":false,"short":"-V","variadic":false},{"description":"Disables autoupdate for one instance of opening up the application","flags":"--disable-auto-update","hidden":false,"long":"--disable-auto-update","mandatory":false,"negate":false,"optional":false,"required":false,"variadic":false},{"description":"If the application was just updated","flags":"--updated","hidden":false,"long":"--updated","mandatory":false,"negate":false,"optional":false,"required":false,"variadic":false},{"description":"Change the user data directory. Used for tests","flags":"--user-data-dir <path>","hidden":false,"long":"--user-data-dir","mandatory":false,"negate":false,"optional":false,"required":true,"variadic":false},{"description":"Ignore https certificate errors","flags":"--ignore-certificate-errors","hidden":false,"long":"--ignore-certificate-errors","mandatory":false,"negate":false,"optional":false,"required":false,"variadic":false}],"parent":null,"processedArgs":[],"program":"[Circular]","rawArgs":["","C:\\Program Files\\BatchExplorer\\BatchExplorer.exe"]},"rawArgs":["","C:\\Program Files\\BatchExplorer\\BatchExplorer.exe"],"timestamp":"2026-03-23T06:07:50.721Z"}
{"level":"info","message":"Registered ms-batch-explorer:// as a protocol for Batch Explorer","timestamp":"2026-03-23T06:07:50.936Z"}
{"level":"info","message":"Registered ms-batchlabs:// as a protocol for Batch Explorer","timestamp":"2026-03-23T06:07:50.936Z"}
{"level":"info","message":"Checking for update","timestamp":"2026-03-23T06:07:52.194Z"}
{"level":"info","message":"Generated new staging user ID: f5e47da2-6e02-5f17-8683-6c585c39cd2d","timestamp":"2026-03-23T06:07:52.195Z"}
{"level":"info","message":"Checking for update (already in progress)","timestamp":"2026-03-23T06:07:52.220Z"}
{"level":"info","message":"Update for version 2.23.0-stable.1210 is not available (latest version: 2.23.0-stable.1210, downgrade is allowed).","timestamp":"2026-03-23T06:07:52.277Z"}
{"level":"info","message":"Restarting application","timestamp":"2026-03-23T06:23:01.548Z"}
{"level":"info","message":"Main Window MainWindowManager closed. Quitting the app.","timestamp":"2026-03-23T06:23:01.649Z"}
{"_actionHandler":null,"_aliases":[],"_allowExcessArguments":true,"_allowUnknownOption":true,"_args":[],"_combineFlagAndOptionalValue":true,"_defaultCommandName":null,"_description":"","_enablePositionalOptions":false,"_events":{},"_eventsCount":5,"_executableFile":null,"_executableHandler":false,"_exitCallback":null,"_hasHelpOption":true,"_helpCommandDescription":"display help for command","_helpCommandName":"help","_helpCommandnameAndArgs":"help [command]","_helpConfiguration":{},"_helpDescription":"display help for command","_helpFlags":"-h, --help","_helpLongFlag":"--help","_helpShortFlag":"-h","_hidden":false,"_lifeCycleHooks":{},"_name":"BatchExplorer","_optionValueSources":{},"_optionValues":{},"_outputConfiguration":{},"_passThroughOptions":false,"_scriptPath":"C:\\Program Files\\BatchExplorer\\BatchExplorer.exe","_showHelpAfterError":false,"_showSuggestionAfterError":false,"_storeOptionsAsProperties":false,"_version":"2.23.0-stable.1210","_versionOptionName":"version","args":[],"commands":[],"level":"info","message":"Program arguments","options":[{"description":"output the version number","flags":"-V, --version","hidden":false,"long":"--version","mandatory":false,"negate":false,"optional":false,"required":false,"short":"-V","variadic":false},{"description":"Disables autoupdate for one instance of opening up the application","flags":"--disable-auto-update","hidden":false,"long":"--disable-auto-update","mandatory":false,"negate":false,"optional":false,"required":false,"variadic":false},{"description":"If the application was just updated","flags":"--updated","hidden":false,"long":"--updated","mandatory":false,"negate":false,"optional":false,"required":false,"variadic":false},{"description":"Change the user data directory. Used for tests","flags":"--user-data-dir <path>","hidden":false,"long":"--user-data-dir","mandatory":false,"negate":false,"optional":false,"required":true,"variadic":false},{"description":"Ignore https certificate errors","flags":"--ignore-certificate-errors","hidden":false,"long":"--ignore-certificate-errors","mandatory":false,"negate":false,"optional":false,"required":false,"variadic":false}],"parent":null,"processedArgs":[],"program":{"_actionHandler":null,"_aliases":[],"_allowExcessArguments":true,"_allowUnknownOption":true,"_args":[],"_combineFlagAndOptionalValue":true,"_defaultCommandName":null,"_description":"","_enablePositionalOptions":false,"_events":{},"_eventsCount":5,"_executableFile":null,"_executableHandler":false,"_exitCallback":null,"_hasHelpOption":true,"_helpCommandDescription":"display help for command","_helpCommandName":"help","_helpCommandnameAndArgs":"help [command]","_helpConfiguration":{},"_helpDescription":"display help for command","_helpFlags":"-h, --help","_helpLongFlag":"--help","_helpShortFlag":"-h","_hidden":false,"_lifeCycleHooks":{},"_name":"BatchExplorer","_optionValueSources":{},"_optionValues":{},"_outputConfiguration":{},"_passThroughOptions":false,"_scriptPath":"C:\\Program Files\\BatchExplorer\\BatchExplorer.exe","_showHelpAfterError":false,"_showSuggestionAfterError":false,"_storeOptionsAsProperties":false,"_version":"2.23.0-stable.1210","_versionOptionName":"version","args":[],"commands":[],"options":[{"description":"output the version number","flags":"-V, --version","hidden":false,"long":"--version","mandatory":false,"negate":false,"optional":false,"required":false,"short":"-V","variadic":false},{"description":"Disables autoupdate for one instance of opening up the application","flags":"--disable-auto-update","hidden":false,"long":"--disable-auto-update","mandatory":false,"negate":false,"optional":false,"required":false,"variadic":false},{"description":"If the application was just updated","flags":"--updated","hidden":false,"long":"--updated","mandatory":false,"negate":false,"optional":false,"required":false,"variadic":false},{"description":"Change the user data directory. Used for tests","flags":"--user-data-dir <path>","hidden":false,"long":"--user-data-dir","mandatory":false,"negate":false,"optional":false,"required":true,"variadic":false},{"description":"Ignore https certificate errors","flags":"--ignore-certificate-errors","hidden":false,"long":"--ignore-certificate-errors","mandatory":false,"negate":false,"optional":false,"required":false,"variadic":false}],"parent":null,"processedArgs":[],"program":"[Circular]","rawArgs":["","C:\\Program Files\\BatchExplorer\\BatchExplorer.exe"]},"rawArgs":["","C:\\Program Files\\BatchExplorer\\BatchExplorer.exe"],"timestamp":"2026-03-23T06:23:04.133Z"}
{"level":"info","message":"Registered ms-batch-explorer:// as a protocol for Batch Explorer","timestamp":"2026-03-23T06:23:04.376Z"}
{"level":"info","message":"Registered ms-batchlabs:// as a protocol for Batch Explorer","timestamp":"2026-03-23T06:23:04.377Z"}
{"http":"http://10.3.1.4:3128","https":"http://10.3.1.4:3128","level":"info","message":"Loaded proxy settings","timestamp":"2026-03-23T06:23:04.378Z"}
{"level":"info","message":"Checking for update","timestamp":"2026-03-23T06:23:05.619Z"}
{"level":"info","message":"Checking for update (already in progress)","timestamp":"2026-03-23T06:23:05.648Z"}
{"level":"info","message":"Update for version 2.23.0-stable.1210 is not available (latest version: 2.23.0-stable.1210, downgrade is allowed).","timestamp":"2026-03-23T06:23:05.709Z"}
{"level":"info","message":"[organizations] Proxying auth endpoints through http://10.3.1.4:3128","timestamp":"2026-03-23T06:24:43.128Z"}
{"level":"debug","message":"[organizations] Trying to acquire token silently","timestamp":"2026-03-23T06:24:43.129Z"}
{"level":"debug","message":"[organizations] Silent token acquisition failed: Error: [internal] No valid account found for silent auth","timestamp":"2026-03-23T06:24:43.131Z"}
{"level":"debug","message":"[organizations] Interactive auth code flow with system browser (Error: [internal] No valid account found for silent auth)","timestamp":"2026-03-23T06:24:43.131Z"}
{"level":"debug","message":"Initialized auth code listener on port 3874","timestamp":"2026-03-23T06:24:43.138Z"}
{"level":"warn","message":"[organizations] Failed to authenticate with browser: ServerError: unknown_error: Error(s): Not Available - Timestamp: Not Available - Description: An unknown error occured.\nHttp status code: NaN\nHttp status message: Unknown\nHeaders: {} - Correlation ID: Not Available - Trace ID: Not Available","timestamp":"2026-03-23T06:26:09.647Z"}
{"level":"error","message":"Error redeeming auth code for a token for resource arm: unknown_error: Error(s): Not Available - Timestamp: Not Available - Description: An unknown error occured.\nHttp status code: NaN\nHttp status message: Unknown\nHeaders: {} - Correlation ID: Not Available - Trace ID: Not Available","timestamp":"2026-03-23T06:26:09.649Z"}
Version:
- OS: Windows 11 and Windows Server 2025
- Version 2.23.0-stable.1210 (Latest at this time)
Workaround:
I applied a workaround based on the LucasForster's post and build it. It seems to have solved the issue.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels