Index: DefaultAccessLogFormatterImpl.java =================================================================== --- DefaultAccessLogFormatterImpl.java (revision 52756) +++ DefaultAccessLogFormatterImpl.java (working copy) @@ -321,9 +321,11 @@ Level.SEVERE, "peaccesslogvalve.missingAccessLogPatternEndDelimiter", pattern); + break; } - String component = pattern.substring(index+1, end); + String component = pattern.substring(index+1, end).trim(); + if (!component.startsWith(ATTRIBUTE_BY_NAME_PREFIX) && !AUTH_USER_NAME.equals(component) && !CLIENT_DNS.equals(component)