We should block resources from web URLs #18608

Closed
opened 2026-01-31 06:19:11 +00:00 by claunia · 14 comments
Owner

Originally created by @mailinglists35 on GitHub (Oct 6, 2022).

Windows Terminal version

1.16.2641.0

Windows build number

10.0.19044.2075

Other Software

WSL1 ubuntu 22.04LTS

Steps to reproduce

open windows terminal preview

Expected Behavior

just show the terminal, not attempt to connect to the internet

Actual Behavior

image

Originally created by @mailinglists35 on GitHub (Oct 6, 2022). ### Windows Terminal version 1.16.2641.0 ### Windows build number 10.0.19044.2075 ### Other Software WSL1 ubuntu 22.04LTS ### Steps to reproduce open windows terminal preview ### Expected Behavior just show the terminal, not attempt to connect to the internet ### Actual Behavior ![image](https://user-images.githubusercontent.com/2054302/194290373-10ae6dd5-3401-44c4-9f39-5255829d7b01.png)
Author
Owner

@mailinglists35 commented on GitHub (Oct 6, 2022):

the type of tab seem to not have any significance. it behaves the same if the default session is cmd.exe as well.

@mailinglists35 commented on GitHub (Oct 6, 2022): the type of tab seem to not have any significance. it behaves the same if the default session is cmd.exe as well.
Author
Owner

@DHowett commented on GitHub (Oct 6, 2022):

We don't have any code that passively attempts to establish a connection anywhere.

If your firewall application blocks further execution of the calling application, this could be a good way for us to find out what it's doing. If that's the case, can you use Task Manager and collect a dump file from WindowsTerminal.exe?

Thanks!

@DHowett commented on GitHub (Oct 6, 2022): We don't have any code that passively attempts to establish a connection _anywhere_. If your firewall application blocks further execution of the calling application, this could be a good way for us to find out what it's doing. If that's the case, can you use Task Manager and collect a dump file from WindowsTerminal.exe? Thanks!
Author
Owner

@lhecker commented on GitHub (Oct 6, 2022):

185.125.190.29 belongs to Canonical and is pointed to by ubuntu.com. I believe the online connection is mis-attributed to us and is actually caused by your WSL setup. This wouldn't be surprising for me as Ubuntu's MOTD contains advertisements for its products. You could try running sudo run-parts /etc/update-motd.d/ to test this.

@lhecker commented on GitHub (Oct 6, 2022): 185.125.190.29 belongs to Canonical and is pointed to by ubuntu.com. I believe the online connection is mis-attributed to us and is actually caused by your WSL setup. This wouldn't be surprising for me as Ubuntu's MOTD contains advertisements for its products. You could try running `sudo run-parts /etc/update-motd.d/` to test this.
Author
Owner

@mailinglists35 commented on GitHub (Oct 7, 2022):

at first I was inclined to dismiss this with suspecting canonical, but I am intrigued by the fact that the firewall triggers even if all wsl sessions stopped and changing default tab to cmd.exe.

sudo run-parts /etc/update-motd.d/ does not seem to trigger the firewall prompt.

image

@mailinglists35 commented on GitHub (Oct 7, 2022): at first I was inclined to dismiss this with suspecting canonical, but I am intrigued by the fact that the firewall triggers even if all wsl sessions stopped and changing default tab to cmd.exe. `sudo run-parts /etc/update-motd.d/` does not seem to trigger the firewall prompt. ![image](https://user-images.githubusercontent.com/2054302/194555597-c1f7436e-0926-409c-a06e-fbfbf1d9fcc4.png)
Author
Owner

@mailinglists35 commented on GitHub (Oct 7, 2022):

also, if wsl does establish the connection itself, how can it technically get in the windowsterminal.exe process network space?

I've had previous firewall prompts for example when doing apt updates for the first time, which did show up in firewall as their own .exe processes, not as windowsterminal.exe

@mailinglists35 commented on GitHub (Oct 7, 2022): also, if wsl does establish the connection itself, how can it technically get in the windowsterminal.exe process network space? I've had previous firewall prompts for example when doing apt updates for the first time, which did show up in firewall as their own .exe processes, not as windowsterminal.exe
Author
Owner

@lhecker commented on GitHub (Oct 12, 2022):

I'm removing the Issue-Bug tag since we have no code that calls canonical.com neither here in this repository nor in any internal bits. We should still figure out why it happens, but I personally can't consider this as a bug anymore.

@lhecker commented on GitHub (Oct 12, 2022): I'm removing the Issue-Bug tag since we have no code that calls canonical.com neither here in this repository nor in any internal bits. We should still figure out why it happens, but I personally can't consider this as a bug anymore.
Author
Owner

@c4bler commented on GitHub (Jan 9, 2023):

This is an issue in Windows 11 where the default cmd.exe is bound to Windows Terminal.

If the dns server is down but the rest of the network is not, cmd.exe flat out fails to open (hangs on what I assume is awaiting response to a tcp connection, likely telemetry but this is a guess). This does not help when trying to diagnose the dns server being down.

@c4bler commented on GitHub (Jan 9, 2023): This is an issue in Windows 11 where the default cmd.exe is bound to Windows Terminal. If the dns server is down but the rest of the network is not, cmd.exe flat out fails to open (hangs on what I assume is awaiting response to a tcp connection, likely telemetry but this is a guess). This does not help when trying to diagnose the dns server being down.
Author
Owner

@DHowett commented on GitHub (Jan 9, 2023):

@c4bler Are you also seeing WindowsTerminal.exe reaching out to the server hosting ubuntu.com?

@DHowett commented on GitHub (Jan 9, 2023): @c4bler Are you also seeing WindowsTerminal.exe reaching out to the server hosting `ubuntu.com`?
Author
Owner

@ejdaly commented on GitHub (Jan 24, 2023):

Am seeing the same behaviour - but only when I have a profile defined for source: CanonicalGroupLimited.Ubuntu_...

Hiding that profile stops the request - but it fires if I open the Windows Terminal Settings.

Commenting out that profile stops the request altogether.

(And commenting it back in, the request fires again as soon as the settings.json is saved).

@ejdaly commented on GitHub (Jan 24, 2023): Am seeing the same behaviour - but only when I have a profile defined for `source: CanonicalGroupLimited.Ubuntu_...` Hiding that profile stops the request - but it fires if I open the Windows Terminal Settings. Commenting out that profile stops the request altogether. (And commenting it back in, the request fires again as soon as the settings.json is saved).
Author
Owner

@DHowett commented on GitHub (Jan 24, 2023):

Interesting!

Can you share the icon and backgroundImage paths for those profiles? You should be able to pull it from the settings UI.

@DHowett commented on GitHub (Jan 24, 2023): _Interesting!_ Can you share the `icon` and `backgroundImage` paths for those profiles? You should be able to pull it from the settings UI.
Author
Owner

@zadjii-msft commented on GitHub (Jan 24, 2023):

omfg

Is this just because their icon is defined as a web resource, so when we load the settings for that profile, we load the icon from the web?

image

Cause I'd bet it is 🤦

We all good closing this out as Resolution-External?

@zadjii-msft commented on GitHub (Jan 24, 2023): omfg Is this just because their icon is defined as a web resource, so when we load the settings for that profile, we load the icon _from the web_? ![image](https://user-images.githubusercontent.com/18356694/214408155-07460b57-ec4d-48b5-b5cb-1d59e9bb24be.png) Cause I'd bet it is 🤦 We all good closing this out as Resolution-External?
Author
Owner

@DHowett commented on GitHub (Jan 24, 2023):

Oh heck.

@DHowett commented on GitHub (Jan 24, 2023): _Oh heck._
Author
Owner

@ejdaly commented on GitHub (Jan 27, 2023):

Yep that's it 😂

(Firewall blocking that request in screenshot below, so no icon...)

image

@ejdaly commented on GitHub (Jan 27, 2023): Yep that's it 😂 (Firewall blocking that request in screenshot below, so no icon...) ![image](https://user-images.githubusercontent.com/1850849/215015586-dd804f08-6de4-43c0-b423-0c8a7b077b2e.png)
Author
Owner

@zadjii-msft commented on GitHub (Aug 23, 2023):

Thanks for all the info, sorry for leaving this on read.

We've collectively decided to repurpose this to "we should block web resources". Mostly for the reason that we don't necessarily want fragment authors to put tracking pixels in their fragments.

This will also require that we do #10359 first, so as to not explode Canonical (or anyone else using this).

@zadjii-msft commented on GitHub (Aug 23, 2023): Thanks for all the info, sorry for leaving this on read. We've collectively decided to repurpose this to "we should block web resources". Mostly for the reason that we don't necessarily want fragment authors to put tracking pixels in their fragments. This will also require that we do #10359 first, so as to not explode Canonical (or anyone else using this).
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#18608