Skip to content

Metadata reading should never use ASM for java.* and javax.* types (in particular on JDK 8) [SPR-11719] #16341

Closed
@spring-projects-issues

Description

@spring-projects-issues

Oliver Drotbohm opened SPR-11719 and commented

If running JDK 8 and the ClassPathScanningCandidateComponentProvider encounters an annotation type during scanning (e.g. in Spring Data JPA where we explicitly scan for interfaces) it tries to read meta-data from java.lang.annotation.Annotation. This type of course was compiled with -target 1.8 for JDK 8 and thus the ASM reader will choke on it. Even if ASM didn't, we shouldn't actually process JDK classes with the ASM reader as it can cause issues with the Security Manager.


Affects: 3.2.8, 4.0.3

Issue Links:

Referenced from: commits 5ab7076, 945335d, e379e77, 9c45755, 2c1203d

Backported to: 3.2.9

Metadata

Metadata

Assignees

Labels

in: coreIssues in core modules (aop, beans, core, context, expression)status: backportedAn issue that has been backported to maintenance branchestype: enhancementA general enhancement

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions