Https is not working for apache tomcat using public ip address - tomcat9

Https is not working for apache tomcat using public ip address

Related

OSB set external ip in generated wsdl

We are using Oracle Service Bus 12c. On our developer server, the default domain configured in jDeveloper runs. The OSB exposes the defined SOAP services locally on port 7101. We wanted these services to be accessible also externally, so we forwarded a port from a firewall server.
Now the SOAP service can be called from the outside, but the generated WSDL (at [serviceurl]?wsdl) states localhost in the address tag at the binding as the location of the server instead of the firewall's IP.
I have tried to set the frontend host and the remote address overwrite properties under protocols -> http for the server, but neither changed the value in the generated WSDL.
Where can I configure the server location for the generated WSDLs?

Create localhost destination

I have some webservices deployed locally and I would like to consume them from my webide instance. I have tried to create the localhost destination but it doesn't work. Its an https services with local certificate deployed locally apache. Is it possible to create a localhost destination ? or should I connect the webservices via cloud connector ?

Intercept all outgoing connections made by a process to redirect it to a localhost proxy

I am working in an environment where there are multiple services hosted. A service(consider web services) exposes some APIs and also acts as client to call other services too.
Now what I want to achieve is that if Service A (acting as client) wants to talk to Service B(acting as server here) using http , then I want to intercept outgoing HTTP request and redirect it to localhost proxy.
There are multiple services running on a host and a service also talks to multiple other services, so I don't want to change the configuration of every outgoing endpoint configuration to point to proxy.
Sample configurations:
Following are the services endpoint which service A connects while doing some processing like:
a1.example.com:2430
a2.example.com:8280
a3.example.com:4380
a4.example.com:4280
a5.example.com:3158
a6.example.com:8238
I have looked into configuring squid proxy as transparent proxy. But how should I enforce every outgoing connection (with different destination ports ) to redirect to localhost proxy.

Hosting WWW and RESTful service ont the same machine

Can a WCF RESTful service and a regular site/www service be hosted concurrently? Or do I need a seperate machine to host WCF?
Thanks.
Yes. they can be hosted on the same machine (depending on whether you are using shared hosting). If you have the permission, you just need to bind them to different ports.
For example, if your website is hosted on port 80 (which is usually the default), then you can create another website on the same machine hosted on port 8080 for the WCF HTTP service.
If your website is a .NET app pool, you can even host the WCF service inside the same app pool as your website, by using a virtual directory.
Also, you can host multiple websites on the same port if you differentiate them by host headers.

WebSphere, sendRedirect and HTTPS

Environment: WebSphere App Server / WebSphere Portal 7, fronted by IBM IHS/Apache httpd using was_ap20_module / mod_was_ap20_http.
I have a servlet or JSP page with a redirect like
response.sendRedirect("/wps/myportal/....")
The generated HTTP ends up with the right host and port for the IHS/Apache endpoint but the wrong protocol. It is http instead of https.
For example, if IHS/Apache is listening on https://myserver.com and WAS is on http://192.168.12.34:12345 (all ports/hosts fake), then my redirect comes back as http://myserver.com - correct host and port but wrong protocol.
How does WebSphere figure out the right host/port to use but not the protocol? How can I force the desired behavior?
Add Apache mod_headers to add a custom header before the request is forwarded to websphere, in websphere, set the httpsIndicatorHeader to that custom header, then websphere will know to switch to https
http://www.ibmconnections.org/wordpress/index.php/tag/was-ssl-http-https/
http://pic.dhe.ibm.com/infocenter/wasinfo/v7r0/index.jsp?topic=%2Fcom.ibm.websphere.express.doc%2Finfo%2Fexp%2Fae%2Frweb_custom_props.html