My JBoss server is running in my system and trying to access it from other system using ip address of my system, but its not accessible and even from my own system i am not able to access using ip.
How can i make jboss enable using ip address.
Thanks
We can run JBoss as ./run.sh -b 127.0.0.1 or run.bat -b 127.0.0.1
This will make JBoss accessible using ip.
If the JBoss is running on your machine you can access it using this URL
http://localhost:<portnumber>
If you have started the JBoss using the command
run.bat>
then you can access the JBoss through above URL only.
If you use this command to start the JBoss :
run –b 0.0.0.0.>
then you can access the JBoss using this URL also
http://<ipaddress>:<portnumber>
In addition to this, if in place of IP address if you want to use some domain name then add that domain name
<IP address> <domain name>
into the host file at this path:
C:\WINDOWS\system32\drivers\etc>
then you can access your jboss through this url
http://<domain name>:<portnumber>
For more details you can check this blog http://tarunjain-jaintarun.blogspot.com/2012/08/acessing-jboss-using-ipaddress.html
Related
We have purchased a Virtual Private Server(VPS) and installed JBoss EAP 7.0.0 on it. We have deployed our application on this VPS JBoss. I am able to access our application on the VPS using "https://localhost:port-number/Our-Application".
However, when I try to access the app from my laptop using the VPS IP address I get "This site can’t be reached "VPS IP address" took too long to respond ERR_CONNECTION_TIMED_OUT". I get the same problem if I try to access http://VPS-IP-Address:8080.
Address wild card for the public interface is set to "Any Address". I tried setting public interface Inet Address to ${jboss.bind.address.management:VPS IP address}/${jboss.bind.address.management:0.0.0.0} it didn't work. I tried starting the JBoss using standalone.bat -b 0.0.0.0 and standalone.bat -b "VPS IP address" it didn't work.
Setting public interface Inet Address to ${jboss.bind.address.public:VPS IP address}/${jboss.bind.address.public:0.0.0.0} also didn't work
I am however able to access JBoss console from my laptop using the VPS IP address(http://VPS-IP-Address:9990/console/App.html#home).
Kindly help.
Regards
Ziauddin Syed
The ports 8080 and 8443 were not open on the VPS. Opened them I was able to access my application
Recently I've set up an Amazon EC2 instance of Ubuntu 16.04 that was authorized to scan an IP block. The version of GSA that I have installed is 7.0.3. Currently, I can locally access GSA through the EC2 instance or remotely using my public Amazon elastic IP.
Additionally, I've allowed external access to GSA's listening port from my IP block. Currently, I can access GSA without any problems using my instances static public IP over HTTPS.
The problem that I'm currently running into is accessing GSA using a FQDN.
For example, I want to be able to use https://gsa.mydomain.com
My local DNS server has an A record with the FQDN and my EC2 instances public IP.
On my instance, I ran the following command.
sudo gsad --allow-header-host gsa.mydomain.com
However, browsing to https://gsa.mydomain.com produces the following error.
"The request contained an unknown or invalid Host header. If you are trying to access GSA via its hostname or a proxy, make sure GSA is set up to allow it."
Neither restarting GSA services or my instance had no effect.
Clearly, DNS is working but the host header command is not.
Any thoughts on how I can make this happen?
Additionally, for reference, I used the following URL
https://github.com/greenbone/gsa/pull/318
In ubuntu/debian edit /etc/default/openvas-gsa file and set ALLOW_HEADER_HOST=HOSTNAME
where HOSTNAME is your host name in the browser address line.
I'm using Kali and was able to figure this out my modifying the systemd service files. Modify the file /lib/systemd/system/greenbone-security-assistant.service, adding the --allow-header-host gsa.mydomain.com to the end of the ExecStart line.
For example, change the line from:
ExecStart=/usr/sbin/gsad --foreground --listen=<internal IP> --port=<configured web server port> --mlisten=<internal IP> --mport=<configured management port>
to:
ExecStart=/usr/sbin/gsad --foreground --listen=<internal IP> --port=<configured web server port> --mlisten=<internal IP> --mport=<configured management port> --allow-header-host gsa.mydomain.com
Then run:
systemctl daemon-reload
systemctl restart greenbone-security-assistant.service openvas-manager.service openvas-scanner.service
I've got a tomcat server instance running inside of eclipse. By default it uses a hostname similar to http://localhost:8080/MyApp/ is there some way to proxy this so I can use a domain name like http://example.com/ instead?
On the production server I use apache to proxy the request to point to the tomcat instance, but within eclipse I don't have that luxury.
I'm using Ubuntu. I thought maybe I could map the domain to point to the localhost version in /etc/hosts but that seems to only be the first step. From there I can't figure out how to point the domain to the tomcat url.
Add this to your hosts file, to access via domain name : localhost example.com
Now, You have couple of options :
Host file doesn't know about ports. You have to access your app like http://example.com:8080/MyApp
You can change your tomcat port 8080 to 80 so that you dont have to access it via port like this http://example.com/MyApp
To access your web application via http://example.com, you have to deploy your application in tomcat root. For that refer Deploying my application at the root in Tomcat
I'm trying to deploy my camel app which on start is creating a cxfrs endpoint. The url is like this: http://localhost:9876 . When I try to hit this one on a rest client or anywhere within my machine it works. But when I try to access it using my phone or other external devices, I'm not able to connect.
Am I missing something?
TIA
Using localhost will mean it is only accessible to your local machine, using 0.0.0.0 instead should make it publicly accessible.
0.0.0.0 should bind all available network interface on your remote machine, but from your description, somehow it only bind to localhost|127.0.0.1 so only accessible from local machine, could you use
http://external.ip.address:9876/foo/FooService
instead to see if it helps?
Also, you can try to access other network service(for example start a tomcat on remote machine and see if you can access it from your local machine) from that remote machine to see if it works, this can determine if your DNS correct or if there's really no firewall between them.
I created a test JBOSS web service and there is only one test method in it. I access this using http://localhost:8070/MyWebService/MyRESTApplication
and it shows the result from the web service. I tried this in both Eclipse and Browser and it works.
But when i want to access this web service using IP address of my system then it shows ERROR message that Page cannot be displayed (in fact browser is not able to find this web service).
I want to access like this http://IPaddress:8070/MyWebService/MyRESTApplication
what should i do so that i can access it using my IP from some computer
You have to start JBoss using :
./run.sh -b [your_IPaddress]
On windows:
start run.bat -b 0.0.0.0
This will tell it to start and bind to all network interfaces. You can also replace 0.0.0.0 with your actual IP if you only want it to bind to that network interface.
I find it easier for debugging to have it come up on all network interfaces because this will work when you are running a virtual machine to debug something like Internet Explorer.
Open your server setting in Eclipse and set Host name as your IP address or 0.0.0.0