SaltySea
SaltySea

Reputation: 740

Changing hostname in WSO2 Identity Server

I'm following WSO2IS's guide to changing hostname and I feel like they're leaving out a rule that I don't know or they're (again) assuming I should know this.

https://docs.wso2.com/display/IS550/Changing+the+Hostname

I'll do a quick rundown of what I did and I'll put the questions at the end. Each numbered list header is referring to the steps in that guide respectively.

  1. I had my Hostname/MgtHostname set as somename.something.ca

  2. I put the original wso2carbon.jks in a separate folder as a backup and created a new keystore "wso2carbon.jks" using this commandline with adjusted values :

    keytool -genkey -alias newcert -keyalg RSA -keysize 2048 -keystore newkeystore.jks -dname "CN=<testdomain.org>, OU=Home,O=Home,L=SL,S=WS,C=LK" -storepass mypassword -keypass mypassword
    
  3. I was able to export a public key from my keystore by adjusting the command line to their appropriate values.

  4. Same thing as step 3, I just changed the values in the command line so it fit with my alias and public key. I was able to import the public key.

  5. Changed "localhost" to "somename.something.ca" everywhere it existed (identity.xml, authenticators.xml etc...)

Everything ran smoothly and I started my WSO2IS service. However, I was not able to reach somename.something.ca (URL does not exist) and when I tried to access my IS, the SAML SSO referred to localhost again (tried this in Incognito mode too)! I don't know why it kept doing that even after I went into my admin dashboard and changed the SAML SSO Identity Provider name from localhost to the new hostname.

For now, I just want to be able to refer to localhost as a different name and at least be able to access my identity server outside my LAN. I should note that I am testing the WSO2IS on a remote desktop (Windows Server) where we do development for the site.

So should I try my hostname as my IP? Does my hostname actually have to exist or can it just be a placeholder? Does my hostname have to be different from 'localhost' so that I may access it outside my LAN? If I change the hostname, am I able to access the dashboard as 'localhost' AND as my new hostname through the computer where I'm running WSO2IS as a service?

I'm sorry for all the questions, I am new to this stuff and I think there is just so much left out of the WSO2 documentation that I need to know in order to make this work.

Your answers are much appreciated.


EDIT: Now with my new hostname setup (after following the guide) and while I'm running WSO2IS, my localhost won't load. If I try going to localhost (on Chrome), it will take 30s then say "localhost took too long to load."

Upvotes: 0

Views: 1011

Answers (1)

SaltySea
SaltySea

Reputation: 740

I'm currently using IIS so what you need to do is create an active website using the manager. I just created a subdomain and plugged that in for every 'localhost' occuring in my .xml files. That allowed me to change my hostname.

Special thanks to gusto2.

Upvotes: 1

Related Questions