[JASPIC_SPEC-1] AppContextID of Servlet profile includes name of virtual host; for which Servlet provides no portable api Created: 13/Feb/13  Updated: 09/Mar/13

Status: Open
Project: jaspic-spec
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Major
Reporter: monzillo Assignee: monzillo
Resolution: Unresolved Votes: 2
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

During programmatic AuthConfigProvider registration - especially
self-registration via

AuthConfigFactory.registerConfigProvider(AuthConfigProvider provider,
String layer,
String appContextID,
String description);

the AuthConfigProvider has no portable way to determine the name of the virtual
host, and thus to register using the same virtual host name that will be used
by the runtime in its call to

AuthConfigFactory.getConfigProvider(String layer, String appContextID,
RegistrationListener listener);

Servlet 3.1 does not intend to provide a portable api by which the name of the
virtual host can be obtained.

this problem was first reported by Arjan Tijms



 Comments   
Comment by arjan tijms [ 09/Mar/13 ]

I just read that the MR document at http://jcp.org/aboutJava/communityprocess/maintenance/jsr196/standard_appContextID_generation.pdf

Mentions the following:

A Servlet container that implements a version of the Servlet specification that defines the getVirtualServerName method on the ServletContext interface, must construct its application context identifiers using a value for hostname that is equivalent to the value returned by calling getVirtualServerName on the ServletContext corresponding to the web application.

I couldn't however find a method called getVirtualServerName on ServletContext. I checked javax.servlet-api-3.1-pdr-javadoc, but it doesn't seem to be there. Is this a method planned for the future?

Comment by arjan tijms [ 09/Mar/13 ]

Even though the method does not seem to appear in the PDR javadoc, I found one reference to it here: GLASSFISH-19814, so it does seem to be a Servlet 3.1 method

Generated at Fri Dec 09 03:54:40 UTC 2016 using JIRA 6.2.3#6260-sha1:63ef1d6dac3f4f4d7db4c1effd405ba38ccdc558.