1

I'm trying to deploy MITRE's OpenID Connect Java Spring Server using Tomcat. My server's FQDN is park.muller.io.

I've compiled the MITRE server and placed the .war file into the Tomcat webapps directory. When I visit park.muller.io:8080/openid-connect-server-webapp, I see the landing page contents... but none of the images or stylesheets resolve. Upon further inspection, the src attribute for the images is a relative URL, but when I right-click on the image and try to view it, it resolves the host to localhost:8080. I've confirmed this behavior on my desktop and on my tablet, so it's not an /etc/hosts issue as I first suspected (I used to have park.muller.io resolve to my home address, but it doesn't do that anymore.)

On park, if I run hostname -f, it returns park.muller.io as expected. This is because I've declared this in /etc/hosts in an effort to fix the problem on my own.

I'm completely baffled; this makes ZERO sense to me. What's making the relative links resolve to localhost, and how can I fix it?

Ryan Kennedy
  • 203
  • 2
  • 11

1 Answers1

0

You need to configure the issuer value inside the server-config.xml configuration file and set it to the final deployment path. This is mentioned in the server configuration documentation but could probably be worded more clearly:

https://github.com/mitreid-connect/OpenID-Connect-Java-Spring-Server/wiki/Server-configuration

Essentially, the Java servlet doesn't make it easy to consistently get the current URL, and even then it will be wrong if you host behind a proxy (such as Tomcat behind Apache using mod_ajp). As such, we decided to just have it be a configuration value in the MITREid Connect server project.

jricher
  • 101
  • 2