Uploaded image for project: 'WildFly Core'
  1. WildFly Core
  2. WFCORE-2827

undefined suffix in rotating-file-audit-log not handled

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Critical Critical
    • None
    • 3.0.0.Beta21
    • Security
    • None
    • Hide

      Try to add following audit log:

      /subsystem=elytron/rotating-file-audit-log=myAppRotate/:add(path=audit.log,format=SIMPLE,max-backup-index=1,rotate-on-boot=false,rotate-size=2000,synchronized=true,relative-to=jboss.server.log.dir)
      

      Creating will fail.

      Show
      Try to add following audit log: /subsystem=elytron/rotating-file-audit-log=myAppRotate/:add(path=audit.log,format=SIMPLE,max-backup-index=1,rotate-on-boot= false ,rotate-size=2000, synchronized = true ,relative-to=jboss.server.log.dir) Creating will fail.

      Attribute suffix of rotating-file-audit-log is optional, but if not filled, following exception occure:

      MSC000001: Failed to start service org.wildfly.security.security-event-listener.myAppRotate: org.jboss.msc.service.StartException in service org.wildfly.security.security-event-listener.myAppRotate: Failed to start service
      	at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1978)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      	at java.lang.Thread.run(Thread.java:745)
      Caused by: java.lang.IllegalArgumentException: Illegal pattern character 'n'
      	at java.text.SimpleDateFormat.compile(SimpleDateFormat.java:826)
      	at java.text.SimpleDateFormat.initialize(SimpleDateFormat.java:634)
      	at java.text.SimpleDateFormat.<init>(SimpleDateFormat.java:605)
      	at java.text.SimpleDateFormat.<init>(SimpleDateFormat.java:580)
      	at org.wildfly.security.audit.RotatingFileAuditEndpoint$Builder.setSuffix(RotatingFileAuditEndpoint.java:289)
      	at org.wildfly.extension.elytron.AuditResourceDefinitions$2.lambda$getValueSupplier$2(AuditResourceDefinitions.java:247)
      	at org.wildfly.extension.elytron.TrivialService.start(TrivialService.java:53)
      	at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:2032)
      	at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1955)
      	... 3 more
      

              jkalina@redhat.com Jan Kalina (Inactive)
              jkalina@redhat.com Jan Kalina (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: