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

HTTPs support #197

Open
Ana06 opened this issue Dec 5, 2024 · 1 comment · May be fixed by #198
Open

HTTPs support #197

Ana06 opened this issue Dec 5, 2024 · 1 comment · May be fixed by #198

Comments

@Ana06
Copy link
Member

Ana06 commented Dec 5, 2024

Does fakenet support HTTPs? I thought the support was added sometime ago, but it does not work in either the latest version (3.3) or the previous one (v3.2-alpha). Is this a fakenet bug or do I need to configure something?

3.3

PowerShell

PS C:\Users\flare\Desktop > Invoke-WebRequest -Uri "https://ana.com/api/123" -OutFile "C:\Users\flare\AppData\Local\Temp\ana.bin" -UseBasicParsing
Invoke-WebRequest : The underlying connection was closed: Could not establish trust relationship for the SSL/TLS
secure channel.
At line:1 char:1
+ Invoke-WebRequest -Uri "https://ana.com/api/123" -OutFile "C:\Users\f ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-WebRequest], WebExc
   eption
    + FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeWebRequestCommand

fakenet

12/05/24 05:52:52 PM [        DNS Server] Received A request for domain 'ana.com' from svchost.exe (2040)
12/05/24 05:52:52 PM [          Diverter] powershell.exe (2832) requested TCP 192.0.2.123:443
12/05/24 05:53:13 PM [          Diverter] explorer.exe (4004) requested TCP 192.0.2.123:443

v3.2-alpha

PowerShell

> Invoke-WebRequest -Uri "https://ana.com/api/123" -OutFile "C:\Users\flare\AppData\Local\Temp\ana.bin" -UseBasicParsing
Invoke-WebRequest : The underlying connection was closed: Could not establish trust relationship for the SSL/TLS
secure channel.
At line:1 char:1
+ Invoke-WebRequest -Uri "https://ana.com/api/123" -OutFile "C:\Users\f ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-WebRequest], WebExc
   eption
    + FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeWebRequestCommand

fakenet

11/28/24 03:47:55 PM [          Diverter] powershell.exe (1360) requested TCP 192.0.2.123:443
11/28/24 03:47:55 PM [          Diverter] svchost.exe (1876) requested UDP 192.168.56.121:53
11/28/24 03:47:55 PM [        DNS Server] Received A request for domain 'ctldl.windowsupdate.com'.
11/28/24 03:47:55 PM [          Diverter] powershell.exe (1360) requested TCP 192.0.2.123:80
11/28/24 03:47:55 PM [    HTTPListener80]   GET /msdownload/update/v3/static/trustedr/en/authrootstl.cab?f909d1009cd4d331 HTTP/1.1
11/28/24 03:47:55 PM [    HTTPListener80]   Connection: Keep-Alive
11/28/24 03:47:55 PM [    HTTPListener80]   Accept: */*
11/28/24 03:47:55 PM [    HTTPListener80]   User-Agent: Microsoft-CryptoAPI/10.0
11/28/24 03:47:55 PM [    HTTPListener80]   Host: ctldl.windowsupdate.com
11/28/24 03:47:55 PM [    HTTPListener80]
@mr-tz
Copy link

mr-tz commented Dec 6, 2024

I suspect this needs #98 or an updated certificate.

#98 would be great to get merged regardless though...

@Ana06 Ana06 linked a pull request Jan 10, 2025 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants