private BundleContext bc;
private Authorization authorization;
+ private Locale locale;
@SuppressWarnings("unchecked")
@Override
}
if (sr.size() == 1) {
CmsSession cmsSession = bc.getService(sr.iterator().next());
+ locale = cmsSession.getLocale();
authorization = cmsSession.getAuthorization();
if (authorization.getName() == null)
authorization = null;// anonymous is not sufficient
}
if (authorization != null) {
- Locale locale = request.getLocale();
- CmsAuthUtils.addAuthorization(subject, authorization,locale , request);
+ // Locale locale = request.getLocale();
+ if (locale == null)
+ locale = request.getLocale();
+ subject.getPublicCredentials().add(locale);
+ CmsAuthUtils.addAuthorization(subject, authorization, locale, request);
CmsAuthUtils.registerSessionAuthorization(request, subject, authorization, locale);
cleanUp();
return true;