Skip to content

4.2.0

Latest

Choose a tag to compare

@ebussieres ebussieres released this 25 Nov 04:52
· 12 commits to master since this release

BREAKING CHANGES

  • default to allowlist method access validation.

Add a configurable allowlist for method access and make it the default. Allow common Java types and Pebble's build-in template objects, and update Spring integration and migration documentation

Methods on application classes must be explicitly allowed. Configure BlacklistMethodAccessValidator or NoOpMethodAccessValidator to restore the previous behavior

A new spring-boot property pebble.allowPackages is added to configure the allowlist for method access validation. It is a comma-separated list of package names. All public methods of classes in these packages and sub-packages will be allowed.

Please consult the documentation for more details: Allowlist mode or for spring-boot integration: Spring Boot Integration

Bug Fixes

  • Resolve ZoneId attributes through the public ZoneId class to avoid illegal reflective access to ZoneRegion (#859).
  • Spring - Allocate reactive view buffer lazily to avoid ByteBuf leak (#863)
  • Isolate macro import aliases between includes (#864)

Security

  • Throw a ParserException for invalid input in double-quoted strings instead of looping indefinitely (#857).
  • Add the configurable default method-access allowlist (#853).
  • Revalidate method access on every invocation, including cache hits, so authorization is checked against the current object instance (#854).
  • Reject FileLoader paths that resolve through symbolic links outside the configured template directory (#856).
  • Traverse cache bodies and embed override blocks during autoescaping to prevent unescaped output (#858).