jxbrowser switch proxy at runtime - jxbrowser

It is posibble to switch proxy at runtime? For example, set a proxy, load a page and change a proxy, load another page. BrowserContextParams.setProxyConfig() does not work at runtime.

JxBrowser allows configuring proxy settings only during initialization and doesn't allow modifying them at runtime: https://jxbrowser.support.teamdev.com/support/solutions/articles/9000013067-working-with-proxy
UPD: In 6.15 we introduced functionality that allows modifying proxy settings at runtime.

Related

How can I change what URL the ASP.NET SPA Proxy directs to once the proxy is online?

In Visual Studio 2022, in the Debug Options there is a way to change the URL that initially loads when you Debug a web application.
However, when using SPA in .net 6.0, the page that initially loads must be the base page, which waits for the SPA Proxy to be online, and then redirects to the SPA Proxy port to load your app when the proxy is ready.
What I'm wondering is if there's any way to set which page this will redirect to, similar to how before using a SPA proxy I could set the debug launch URL to be different from the base / page.
The bundler I am using is Vite, and I have tried using the vite server "open" option to select a URL to open when the server launches. Unfortunately since this is separate from asp.net's proxy logic, they both open. The whole point is I'm trying to avoid loading the base / page.
I have tried modifying the .csproj file so that the SpaProxyServerUrl doesn't just have a port but has a full url, aka from <SpaProxyServerUrl>https://localhost:44466</SpaProxyServerUrl> to <SpaProxyServerUrl>https://localhost:44466/Developer</SpaProxyServerUrl>, but when I do this the spa proxy doesn't launch at all, and the index.html file doesn't load (which is configured in Program.cs with app.MapFallbackToFile("index.html");
Is there a setting I'm missing somewhere? Or does anyone have any ideas on how I can accomplish this? Thank you.
In case anyone else is having the same problem in the future, I was able to get it to work. Strangely for some reason the spa proxy wouldn't let me load my base page (localhost:44366) and load the spa proxy and redirect to localhost:44466/Developer.
However, it worked when both sides were configured to use the same endpoint.
So I changed the debug launch settings to load localhost:44366/Developer and also changed the .csproj's SpaProxyServerUrl to localhost:44466/Developer and then it worked.
No clue why it's setup this way but this change worked for me with .net 6

Not able to edit Public Server Name for embedded Tomcat

we are using Artifactory 6.20.0 in docker-compose mode. Stack is up and running fine. But I am not able to edit the "Public Server Name" in HTTP settings. It is greyed out.
How can I change it?
From Which file TomCat picks these values?
As per my understanding If I change Http settings and use nginx or tomcat. Still my Artifactory is reachable using same address which embedded Tomcat has provided and nginx will be only used for the path based routing. or nginx takes care of both parts?
Please note 'HTTP settings' in Artifactory UI is a template to generate the reverse proxy configuration according to provided fields and you can use the same snippet downloaded and install directly in the corresponding directory of your reverse proxy server.
Answers to your queries:
Embedded tomcat will not pickup any values from this template, it runs on 8081 (over http) by default.
As stated above, changing Http settings in UI will not help as it is a simple template. You must have a reverse proxy installed and place the required configuration on reverse proxy directories in order to access Artifactory over a DNS(http/https). Please refer to Configuring Reverse Proxy wiki page for more details.

Artifactory. How to disable access via native browser

I use Artifactory аs a private repository. I take link on my repository to use it to gradle. However, if you enter this link in the browser, you will be able to download the jar file from the browser. How can I disable this functionality?
Artifactory does not have built in functionality for disabling the Web UI.
Depending on your use case you can block access to the UI by limiting access to the Web UI using an HTTP proxy in front of Artifactory (or an organizational proxy, firewall etc).
For example, you can limit the access to the web UI only to certain IP address or address ranges.
If you want to completely block web browsers from accessing Artifactory you can configure the reverse proxy to block certain user agents.
CloudRepo provides private and public repositories, if you'd like to prevent anyone from using your stuff you can toggle that repository to private.

F5 Add apm_do_not_touch to HTML response to the end user

I am supporting ASP.NET application running on 3 web servers and have F5 system as firewall and load balance. Actually I don't have experience at all in F5 system but the following issue seems to be related to it
The issue happened after we applied F5 load balancing. Simply it cause JavaScript in the web page to fail sometimes. After refresh the web page it will work fine
To trace the issue I compared the response that fail and the one that success after refresh. The difference was the failed one contains html tag that is not added by our application apm_do_not_touch with a script tag inside it
It seems that happen when the F5 switch between one server to another one as the issue solved when we redirect all the traffic to only one server
Any advice, what is the possible cause and how we can solve it?
APM is F5's Access Policy Manager module and is used for VPN, Web Portals, and federated authentication. The apm_do_not_touch tag is part of this product and is used when you want to prevent the APM module from rewriting portions of HTML such as external links.
If you're not accessing the application through a web portal, this should not be applied and you'll need to work with whomever setup the access policy to resolve as the APM policy is being applied to your application possibly erroneously.
Here is more information on the apm_do_not_touch tag. Depending on your version, there was a known issue for #cc_on in F5 BIG-IP version 11.1 who's workaround was to prevent the APM module from rewriting that command. The same workaround may pose a solution for you. Either way, there are additional complexities to your client traffic flow that you will need to engage your network team/BIG-IP administrators with to ensure your application and their policies don't clash.
It could be as simple as removing the APM policy from your application's pathway but your admins will be able to identify if it's required for external access or reverse proxy requirements.

while enabling the omega theme live reload error

I'm new to Drupal and I just started with theming. After enabling the omega theme, I'm getting this error:
LiveReload is currently enabled but could not be loaded. Please ensure
that livereload.js is being served at the configured path
(http://localhost:35729/livereload.js?snipver=1).
What can I do avoid the error?
After looking for a solutions on Google and I found few of them and I have mentioned below under solutions.
What is LiveReload?
LiveReload is a tool for web developers and designers.
To use LiveReload, you need a client (this script) in your browser and a server running on your development machine.
This repository (livereload.js) implements the client side of the protocol. The client connects to a LiveReload server via web sockets and listens for incoming change notifications. When a CSS or an image file is modified, it is live-refreshed without reloading the page. When any other file is modified, the page is reloaded.
You should refer to your LiveReload server/app/tool's documentation, rather that this repository. You should use the copy of livereload.js script bundled with your server, because it's guaranteed to be compatible, and may be customized for that server.
Solutions I found
The message just means that livereload.js can't be loaded LiveReload is enabled in the theme settings but not working because Guard is not running). Fix: Run Guard or disable LiveReload.
navigate into your theme's folder via your CLI (Terminal, et.al.) and run this command:
$ drush omega-guard

Resources