Uploaded image for project: 'logback'
  1. logback
  2. LOGBACK-1182

Problem deserializing AccessEvent.

    XMLWordPrintable

Details

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • None
    • 1.1.7
    • logback-access
    • None

    Description

      I receive the following messages in Lilith while deserializing events sent by ch.qos.logback.access.net.SocketAppender from within my logback-access-sandbox:

      • Unauthorized deserialization attempt! org.springframework.web.servlet.FlashMap
      • Unauthorized deserialization attempt! org.springframework.util.LinkedMultiValueMap

      Those messages are created by my own WhitelistObjectInputStream whenever it sees an unexpected class. This is done for security reasons. More info is included in the source linked above.

      The problem is that even if I whitelisted those classes, they aren't necessarily available on the receiving ends classpath. They are a webcontainer implementation detail that leak through the AccessEvent.

      The messages show up since I switched my sandbox from manual servlet to spring-boot. I suspect that shouldCopyAttribute in ch.qos.logback.access.spi.AccessEvent is the culprit since it copies everything that is Serializable. Everything else in AccessEvent looks safe.

      This should be fixed. I'm just not sure about how to fix it exactly... maybe doing toString() during copy?

      Attachments

        Activity

          People

            logback-dev Logback dev list
            jhuxhorn Joern Huxhorn
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: