How do I make a proxy that reroutes all outbound requests to another server?
2024.04.09 03:19 XplodingSpwnHow do I make a proxy that reroutes all outbound requests to another server?
(If this is the wrong place for this, tell me where I should go for help) What the title says. I want to make code that allows me to redirect any outbound requests to any IP or URL from my computer to somewhere else automatically. For example, a GET request going to watch.youtube.com/hello redirects the request to proxyurl.net/watch.youtube.com/hello. How would I go about doing this?
2023.12.31 05:03 professional_poleConfig.yml file read only, can't make it writable
Newish user to linux, very fresh user to Vikunja. Why is the config.yml file read only, and why can i not change its permissions no matter what level of permission i try to do it with? I tried using chmod u+w config.yml, then sudo chmod u+w config.yml neither worked, only the non sudo one gave me any feedback at all i haven't tried using the octal codes yet but i had no idea why those would work when the regular way didn't i want to turn on the mailer (btw, seperate question, is this plug and play when it comes to the self hosted version?) and the proxyurl stuff.
2023.10.25 19:04 shellbeachhhHow to convert links within text to linked titles of webpage?
I have started to do this, but my approach is just one. If you prefer to replace my entire approach (rather than just correct it), I'm fine with that. Goal is to paste text into a box. The text includes regular text (with paragraphing) and http://links. When button is pressed, I want it to print my text as it was (with paragraphs) but replace the http://links with linked titles of the webpages. Link Converter
2023.10.15 14:50 Flimsy-Bug-1463Application level proxy setting in NodeJS
Hi Everyone, I'm trying to send one request from application to hit external URL. It works good in local not in server. In server I'd to include proxy. Proxy has been set in environmental level in server. I Confirmed it by curl proxyurl http://example.com. It's working good in server. But not from the application in the server. I'm using a npm library called splunk-sdk. From there only the http request is being sent. There is no inbuilt proxy parameter there. How to set proxy globally to make every http request to use the proxy?
This is a bit complicated, at least for me. So I am trying to change the service behind the proxy depending on the user returned from a SAML connection using MELLON. After a lot of trial, error and keyboard face rolling, I gave up. However, I do know that I can successfully set headers from SAML that can be read by the backend server. Using a PHP docker container I simply made an index.php that had var_dump($_SERVER), and I could see the correct variables and values. TLDR: Mellon passes X-WEBAUTH-USER to the backend server, and I have verified using a PHP server that this works by dumping $_SERVER. However I cannot figure out some intelligent logic or rewriterules to change the proxypass based on this value. Would this be the correct way to set an environment variable from the request header?
Also tried If/Else statements which didnt seem to work either. Any ideas or suggestions? So my MELLON reverse proxy has this config:
ServerName https://tools.company.com ServerAlias localhost ProxyRequests On ProxyPreserveHost On ProxyPass /mellon/ ! Require valid-user AuthType "Mellon" MellonEnable "auth" MellonVariable "cookie" MellonSecureCookie on MellonCookiePath / MellonUser "NAME_ID" MellonSessionDump On MellonSamlResponseDump On MellonEndpointPath "/mellon" MellonDefaultLoginPath "/" MellonSessionLength 28800 MellonSignatureMethod rsa-sha256 ## MultipleSP Test # service provider metadata, cert, and key MellonSPPrivateKeyFile /etc/apache2/mellon/saml_sp.key MellonSPCertFile /etc/apache2/mellon/saml_sp.cert MellonSPMetadataFile /etc/apache2/mellon/saml_sp.xml MellonIdpMetadataFile /etc/apache2/mellon/saml_idp.xml RequestHeader set "X-Forwarded-Proto" expr=%{REQUEST_SCHEME} RequestHeader set "X-Forwarded-SSL" expr=%{HTTPS} MellonSetEnvNoPrefix REMOTE_USER NAME_ID MellonSetEnvNoPrefix REMOTE_EMAIL emailaddress MellonSetEnvNoPrefix "ADFS_EMAIL" "http://schemas.xmlsoap.org/ws/2005/05/identity/claims/emailaddress" RequestHeader set X-WEBAUTH-USER %{REMOTE_USER}e env=REMOTE_USER RequestHeader set X-WEBAUTH-EMAIL %{ADFS_EMAIL}e env=ADFS_EMAIL DEFINE proxyurl "saml-splitter" DEFINE proxyport "80" ProxyPass http://${proxyurl}:${proxyport}/ ProxyPassReverse http://${proxyurl}:${proxyport}/
Which then goes into my "splitter", in hopes of reading this request header (I think that's the correct term?) and changing the proxy. You can see some of the previous attempts I have commented out and didn't seem to work. Wanted to keep them here as I have tried a lot of different things
2023.01.09 22:15 ICanSeeYou7867IF/ELSE implentation with mellon?
I am trying something out, and I am curious if I am heading down the right path, or if this is not even possible. I have auth mellon working with our companies SAML ADFS provider without issue. But, I wanted a reverse proxy to change depending on who accesses it. So if NAME_ID contains X, proxy destination is Y, else proxy destination is Z. Logically this makes sense to me, but it is always evaluate as false. Hopefully someone smarter than me might know. I feel as though there is something fundamental that I am missing. Thanks for looking!
2022.08.02 17:17 DIBSSBDHow to configure STOCKS5 Proxy (nord)with auth with username and pass in qbitorrent.conf ?
I want to preconfigure this result in qbitorrent.conf file I want to preconfigure the stocks5 with auth=true how to do that in "qbitorrent.conf" files i tried but failed need help this is what I have triedthis is my qbitorrent.conf Case:1 [Preferences] Connection\PortForwardingEnabled=false Connection\Proxy\IP=proxyurl Connection\Proxy\OnlyForTorrents=trueConnection\Proxy\ProxyForPeerConnections=true Connection\Proxy\Password=my nord pass Connection\Proxy\Port=1080 Connection\Proxy=true Connection\Proxy\Username=my nord username Connection\ProxyType=2 This config resulted in this I want to click ☑️ in these 3 fileds how to do this ?? ☑️ via qbitorrent.conf Case 2 [Network] PortForwardingEnabled=false Proxy\IP=nord Proxy\OnlyForTorrents=true Proxy\Password=my nord pass Proxy\Port=1080 Proxy\Type=SOCKS5_PW Proxy\Username=my nord username This did not work at all. How do I enableOnly For Torrents, Proxy For Peer Connections, and authentication ?Please some one help me regarding this as I am constantly getting emails from my isp I am using this repo for qbitorrent web github/anasty17/mirror-leech-telegram-bot and this is the config which I have edited which did not work Does anyone knows wiki or how to use qbitorrent.conf and fix this issue ??
2021.09.01 21:16 dhcgnError "The system cannot find the file specified" while http call
I got an unexpected error %!(EXTRA string=The system cannot find the file specified.) when calling method RoundTrip(req *Request) from http.Transport. Error occurs on a Windows 10 Enterprise (19041) maschine. Not my maschine, so no debugging
Implementation
This go application is only a simple reverse proxy which adds TLS Client Auth. ```go transport:= &http.Transport{ DialContext: (&net.Dialer{ KeepAlive: 1 * time.Minute, Timeout: 1 * time.Minute, }).DialContext, IdleConnTimeout: 1 * time.Hour, TLSHandshakeTimeout: 20 * time.Second, ExpectContinueTimeout: 20 * time.Second, ResponseHeaderTimeout: 1 * time.Minute, MaxIdleConns: 100, MaxIdleConnsPerHost: 4, } if ProxyURL != nil { transport.Proxy = http.ProxyURL(ProxyURL) } transport.TLSClientConfig = &tls.Config{ Certificates: []tls.Certificate{certificate}, } response, err := transport.RoundTrip(r) if err != nil { t.Logger.Errorf("Error at send to %v in %vms with error ", r.URL, elapsed.Milliseconds(), err.Error()) } ```
certificate is a tls.Certificate
r is a *http.Request
Error Message
Error at send to https://example.org:443 in 88ms with error %!(EXTRA string=The system cannot find the file specified.) How to interpret this error message? Why does it says file when it is a http call? My guess is, that a Windows Api Call cannot find a file. But I'm uncertain by this conclusion. Link to implementation of net/http/transport.go: https://github.com/golang/go/blob/e9e0d1ef704c4bba3927522be86937164a61100c/src/net/http/transport.go#L504
2021.06.08 10:19 Additional-Feature33Is this a CORS issue? JS beginner here.
I'm trying to connect with the Unsplash API, using a fetch request, and storing results in a variable. Weird thing, I could see the photos array pull up in my console, however it stopped working randomly and whenever I console log now, i get this issue: "Indicate whether to send a cookie in a cross-site request by specifying its SameSite attribute" I tried to combine the apiUrl with the proxyUrl = ('https://cors.anywhere-herokuapp.com/'), But im still getting the issue.
2021.06.08 09:09 Additional-Feature33Is this a CORS issue? JS beginner here.
I'm trying to connect with the Unsplash API, using a fetch request, and storing results in a variable. Weird thing, I could see the photos array pull up in my console, however it stopped working randomly and whenever I console log now, i get this issue: "Indicate whether to send a cookie in a cross-site request by specifying its SameSite attribute" I tried to combine the apiUrl with the proxyUrl = ('https://cors.anywhere-herokuapp.com/'), But im still getting the issue.
Hi, I'm looking for some help. We've made a greenfield deployment of vSphere 7 for one of our clusters, all went smooth as expected but we have an issue with proxy settings for vSAN health check and in the vcsa vami. Our internet proxy setup is based in squid and it requires authentication, as is localted in dmz we cannot configure it via VAMI because it checks icmp but we edited /etc/sysconfig/proxy manually adding the proxy in this format https://user:pass@proxyurl:port as documented in several forums. The connections to the proxy went ok and the proxy admins see traffic but without autentication. Also for vSAN online health in the vCenter settings we add the setting and the same issue. There is something else we should setup to allow authenticated connection to the internet proxy? Best Regards
2020.02.02 02:29 laurajonesesesesHTTP request only works with a proxy url, otherwise I get pre-flight CORS errors. What is going on?
I can't connect to this API when I'm trying to work on my laptop, like I have other APIs I've worked with, unless I use a proxy url, and I don't understand why. When I try to connect it throws an error: Access to XMLHttpRequest at 'http://metals-api.com/api/latest?access_key=[Redacted]' from origin 'null' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: Redirect is not allowed for a preflight request. Here is the code that throws that error:
I'm trying to run the file from my desktop, in the browser, so just from a local file on my machine. What does this proxy url do that makes it magically work? Do I need to add something to my code, or will this not be a problem if I deploy to a host like Heroku? I'm just using Vanilla JS, no Node. Do I need to use node to get this to work without the proxy?
2019.04.08 12:42 czechsysAnybody being annoyed by CDN/firewall for repositories? There is no solution yet?
I hate CDNs, especialy, when their FQDN doesn't match. Installing gitlab-runner. Apt repository for it is on packages.gitlab.com /somepath. Great. Added as repo, allowed on firewall. Now updated. Apt failed. Looking why. Hm, packages-gitlab-com.s3-accelerate.amazonaws.com. Welcome to the hell start. So we need proxy. We can't use transparent (because no difference between apt and other services). So we need standalone proxy. Great, we need standalone proxy in every location, because...all inet services are over bgp via lambda. Hell raised. So tried: Acquire::http::Proxy::packages.gitlab.com "PROXYURL:PORT" Failed to connect packages-gitlab-com.s3-accel...........Hell overrun Earth.
2019.04.04 20:01 LBEB80Exchange errors after decommissioning secondary forest and trust
Howdy, We have an Exchange 2016 installation on DomainA. We had a forest trust with DomainB. All users of DomainB had linked mailboxes to the Exchange server. Since this was setup, we migrated all users from DomainB to DomainA. The old domainB was decommissioned and then the forest trust was removed. Since then Exchange has been complaining alot with references to the old DomainB. Below are the three main ones that repeat themselves. Process 15428: Failed to connect to the Active Directory in the remote forest DomainB. Please check for misconfigurations on the ServiceBinding attribute on the Service Connection Point object CN=DomainB,CN=Microsoft Exchange Autodiscover,CN=Services,CN=Configuration,DC=DomainA,DC=org in the Active Directory. Process w3wp.exe (MapiAddressBook) (PID=15428). WCF request (GetServerFromDomainDN DC=DomainB,DC=com) to the Microsoft Exchange Active Directory Topology service on server (TopologyClientTcpEndpoint (localhost)) failed. Process Microsoft.Exchange.Directory.TopologyService.exe (PID=3272). Error DNS_ERROR_RCODE_NAME_ERROR (0x8007232B) occurred when DNS was queried for the service location (SRV) resource record used to locate a domain controller for domain DomainB.com. The query was for the SRV record for _ldap._tcp.dc._msdcs.DomainB.com
Good Morning All! I hoping that someone may shed some light on this. I have a script that does an login check on an external website for us and reports back if it was successful or not. It was having issues on our production box (PS 4 Win 2012 R2) with the proxy, but I added the following to an Invoke-WebRequest statement:
-Proxy $my_proxyurl -ProxyUseDefaultCredentials
And this worked great. I wanted to plug the script into our monitoring software, Avada IR360 (Infared 360), this executes the script every so often and has conditions on when to create tickets. I have a specific workaround I have to do with this, because Avada runs as SYSTEM user, which has never of course used IE. I use Invoke-Command to run the rest of the script as a special domain user: $result = Invoke-Command -ComputerName localhost -Credential $stored_creds -ScriptBlock This normally works, however, now the proxy is throwing errors as me again. Missing credentials, invalid token, etc. I have tried specifying the credentials or using the default. The proxy uses SSO. Anyone have any idea why the proxy is now denying me again? I do have IT Security team looking to see if something is not being passed to the proxy right, but just wanted to pick someone else's brain. Thank you!
2018.10.03 01:56 habibexpressNoob question - BuildAgents on AWS behind a Proxy
Hi All, I'm having great difficulty in trying to get a build agent working properly behind a CC-Proxy connection. Has anyone managed to successfully setup a Windows based build agent behind a proxy connection? When we have build agent with direct internet connection, we have no issues. When behind a proxy server and after defining the proxy server in .\config.cmd --proxyurl, deployments don't get pushed from Nuget. We then add a task to echo the proxy address in before executing the build task. Any help with this would be greatly appreciated. Thanks.
2018.09.19 01:46 habibexpressVSTS Build Agent on AWS EC2
Hi All, I've got a situation where we've started exploring using VSTS build agents in the cloud hosted on AWS. Our infrastructure is simple. It consists of, in this case:
DEVOPS - Jump machine into the network, database server and runs a CCProxy server.
BuildA - Build agent machine, configured to use DEVOPS machine as the proxy server. Internet works.
The build machine has been registered against our cloud VSTS and we can see its status as online. The agent on the BuildA machine has been configured to run with a proxy, with the argument:
We know proxy url works because without it, we were unable to communicate with VSTS to register the new BuildA agent. We can successfully use it to build projects, however, it fails at the task of installing the Visual Studio Test Platform Installer and therefore any associated tests of the application. Error from VSTS web page: https://i.imgur.com/1QPNJMv.png full error:
2018-09-18T02:47:39.9405032Z ##[section]Starting: Visual Studio Test Platform Installer 2018-09-18T02:47:39.9849865Z ============================================================================== 2018-09-18T02:47:39.9850342Z Task : Visual Studio Test Platform Installer 2018-09-18T02:47:40.0227918Z Description : Acquires the test platform from nuget.org or the tools cache. Satisfies the ‘vstest’ demand and can be used for running tests and collecting diagnostic data using the Visual Studio Test task. 2018-09-18T02:47:40.0228808Z Version : 1.1.1 2018-09-18T02:47:40.0229015Z Author : Microsoft Corporation 2018-09-18T02:47:40.0229578Z Help : Test platform package on NuGet 2018-09-18T02:47:40.0229837Z ============================================================================== 2018-09-18T02:47:41.9058891Z Starting VsTest platform tools installer task. 2018-09-18T02:47:41.9059581Z ============================================================================== 2018-09-18T02:47:41.9083744Z Looking for the latest pre-release version of the Microsoft.Testplatform. 2018-09-18T02:47:41.9127378Z [command]C:\agent\_work\_tasks\VisualStudioTestPlatformInstaller_2c65196a-54fd-4a02-9be8-d9d1837b7111\1.1.1\nuget.exe list packageid:Microsoft.TestPlatform -PreRelease -NonInteractive -Source https://api.nuget.org/v3/index.json 2018-09-18T02:48:46.5402410Z Unable to load the service index for source https://api.nuget.org/v3/index.json. 2018-09-18T02:48:46.5402768Z An error occurred while sending the request. 2018-09-18T02:48:46.5402972Z Unable to connect to the remote server 2018-09-18T02:48:46.5403280Z A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 117.18.232.200:443 2018-09-18T02:48:46.5407885Z ##[error]Nuget.exe returned error code: 1 2018-09-18T02:48:46.5409768Z ##[error]Failed to fetch list of available packages from nuget, looking for latest stable version cached. Error: Listing packages failed. Nuget.exe returned 1. Standard Error: Unable to load the service index for source https://api.nuget.org/v3/index.json. An error occurred while sending the request. Unable to connect to the remote server A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 117.18.232.200:443 Standard Out: 2018-09-18T02:48:46.6072999Z ##[error]Failed to find any stable version of the test platform package in the cache. 2018-09-18T02:48:46.6801655Z ##[error]Error: Failed to acquire the test platform. Please set system.debug to true and refer to the debug logs for additional information. 2018-09-18T02:48:46.6803804Z ##[section]Finishing: Visual Studio Test Platform Installer
On another build server, which has direct access to the Internet, the platform installer is successful, the tests execute, complete, pass and build successfully.
2018-09-18T02:59:27.9069960Z ##[section]Starting: Visual Studio Test Platform Installer 2018-09-18T02:59:27.9218816Z ============================================================================== 2018-09-18T02:59:27.9219098Z Task : Visual Studio Test Platform Installer 2018-09-18T02:59:27.9241430Z Description : Acquires the test platform from nuget.org or the tools cache. Satisfies the ‘vstest’ demand and can be used for running tests and collecting diagnostic data using the Visual Studio Test task. 2018-09-18T02:59:27.9242159Z Version : 1.1.1 2018-09-18T02:59:27.9242310Z Author : Microsoft Corporation 2018-09-18T02:59:27.9242511Z Help : Test platform package on NuGet 2018-09-18T02:59:27.9242757Z ============================================================================== 2018-09-18T02:59:29.7386932Z Starting VsTest platform tools installer task. 2018-09-18T02:59:29.7387481Z ============================================================================== 2018-09-18T02:59:29.7408711Z Looking for the latest pre-release version of the Microsoft.Testplatform. 2018-09-18T02:59:29.7449855Z [command]C:\agent\_work\_tasks\VisualStudioTestPlatformInstaller_2c65196a-54fd-4a02-9be8-d9d1837b7111\1.1.1\nuget.exe list packageid:Microsoft.TestPlatform -PreRelease -NonInteractive -Source https://api.nuget.org/v3/index.json 2018-09-18T02:59:33.6242181Z Microsoft.TestPlatform 15.9.0-preview-20180816-01 2018-09-18T02:59:33.7056314Z Found tool in cache: VsTest 15.9.0-preview-20180816-01 x64 2018-09-18T02:59:33.7057027Z VsTest will use the Test Platform package found in C:\agent\_work\_tool\VsTest\15.9.0-preview-20180816-01\x64 2018-09-18T02:59:33.7448514Z ##[section]Finishing: Visual Studio Test Platform Installer
Executing the failing NuGet install directly from the commandline, I see the following Command:
cd C:\agent\_work\_tasks\VisualStudioTestPlatformInstaller_2c65196a-54fd-4a02-9be8-d9d1837b7111\1.1.1\
Output:
C:\agent\_work\_tasks\VisualStudioTestPlatformInstaller_2c65196a-54fd-4a02-9be8-d9d1837b7111\1.1.1>nuget.exe list packageid:Microsoft.TestPlatform -PreRelease -NonInteractive -Source https://api.nuget.org/v3/index.json Microsoft.TestPlatform 15.9.0-preview-20180816-01 C:\agent\_work\_tasks\VisualStudioTestPlatformInstaller_2c65196a-54fd-4a02-9be8-d9d1837b7111\1.1.1>
2018.08.15 20:05 StarFoxLombardiUnable to install bundler/gems after upgrading jruby and rubymine version
Hi all, So recently my team was encountering some SSL cert issues so in order to help fix that, we've upgraded our jruby 1.7.4 to jruby 9.1.15 and our RubyMine to 2018.2.1. However, now we're facing an issue installing /updating gems and bundler after the upgrade. We're trying to install from the command prompt going: $ set HTTP_PROXY=https://username:[password@proxyurl.net](mailto:password@proxyurl.net):port $ gem install bundler And receiving the error: ERROR: While executing gem ... (OpenSSL::SSL::SSLError) Received fatal alert: protocol_version Before setting the proxy the error was: WARNING: Unable to pull data from 'https://rubygems.org/': SocketError: Failed to open TCP connection to rubygems.org:443 (initialize: name or service not known) (https://rubygems.org/specs.4.8.gz) 1 gem installed I've even tried going to a Starbucks to avoid the proxy altogether but am still getting a similar error. Just to add in trying to install bundler in RubyMine itself doesn't work. Any help would be so greatly appreciated thanks. Edit: Solved-ish.. Okay so I don't know how I fixed it. But the bundler ended up getting installed through command prompt and I guess I restarted and was able to install gems through RubyMine itself but was still getting the same error through CMD. So I guess that's the only practice that works?
2018.02.14 12:29 KarkuroRetrieve config or env variable in Vue component
I have a Vue component in my Laravel application. I want to retrieve a URL that is in a config (that retrieves my .env variables) directly in my Vue component, instead of hardcoding it. For example, in webpack laravel mix I can retrieve my .env variable like this.
require('dotenv').config() let proxyUrl = process.env.APP_URL
But when I want to do this in my app.js, I have a "can't resolve fs" when trying to require dotenv. I would like to retrieve a laravel config data, directly in my .vue file. What is the best way to have this data available in my Vue components ?
2017.07.29 00:59 RaithZGetting SSL handshake failure when connecting to proxy_pass host that has self-signed SSL Cert
I have nginx running and have setup a reverse proxy configuration to connect to an internal address such as https://10.10.9.11:433 When I connect to the external address which has a valid SSL certificate, I get 502 bad gateway. When I check the NGinx error.log file I have the following:
I have done a good amount of googling but I can't seem to find any answer that works. The device at 10.10.9.11 has a self signed certificate, which I suspect may be part of the problem, but again I don't know. I am not trying to do SSL pass through... the goal is to have the SSL be handled by niginx, the back-end devices just have SSL enabled and you can't turn it off. Might anyone have an idea what i'm missing or what I need to do make this work? Any help/guidance/advice is welcome and would be greatly appreciated. Edit: Added Code spaces For readability