+ Start a Discussion
Joe GaskaJoe Gaska 

Sites Security Issue Using Custom URL + Customer Portal


Question: Will tabs in the customer portal appear if you are using a custom URL?  My Theory is no




We are using Sites to host the anonymous website and using the customer portal as login from sites into managing your own data.  What we are experiencing is the only tab which will appear is the "home" tab if you are using the custom URL within the portal.  Login is successful and sites work as expected, authentication works but page rendering does not.  

If we change the url from "www.CustomUrl.com" to "na1.salesforce.com" all tabs appear as expected.  Login successful all you do is change URL and tabs appear/disappear because of the url used.


Does Not Work: http://www.CustomURL.com/home/home.jsp?retUrl=/home/home.jsp


Does Not Work:  http://SiteName.Force.com/home/home.jsp?retUrl=/home/home.jsp


Works: http://na1.salesforce.com/home/home.jsp?retUrl=/home/home.jsp


We have validated the customer portal works as expected using the standard URL.  Since the security is correctly authenticating the user and allowing entry to the customer portal how/why would the tabs be displayed differently?  The only time all tabs appear is when you use the na1.salesforce.com and it does not even request you login you simply change the URL and tabs appear/disappear.



1.) Require Non-Secure Connections (HTTP) = True

2.) We redirect them upon successful login to http://www.CustomURL.com/home/home.jsp?retUrl=/home/home.jsp

3.) Page renders with authenticated user and only tab that appears is "home"

4.) If we login from the contact record and view user in portal then all tabs appear correctly.  Change URL they disappear.


DNS Information 


www.CustomURL.com has a CNAME pointing to SiteName.force.com    

Pointed www.CustomURL.com to point to Na1.SalesForce.com vs SiteName.force.com  waited 24 hours did not work.





Any thoughts?





For my Site, I set the startURL to '/home/home.jsp' and the login redirect works well (the tabs appear). Below is the two lines of Apex code in my controller that sets the StartURL when logging in:



String startURL = '/home/home.jsp';
return Site.login(username, password, startUrl);