spring-projects / spring-projects/spring-security
`AbstractConfiguredSecurityBuilder.getSharedObject` should be marked `@Nullable`
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 9.6k
- Forks
- 6.3k
- Avg merge
- 2d 11h
- Merged PRs (30d)
- 52
Description
Describe the bug
AbstractConfiguredSecurityBuilder is in a @NullMarked package, is documented to possible return null, but its return type is not @Nullable.
This causes erroneous results from static analysis tools.
Expected behavior
Anything that can be null should be marked @Nullable, since the default was set to be @NonNull in Spring Security 7.
Previous instances of this bug: #18275, #18259
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Locate AbstractConfiguredSecurityBuilder and inspect getSharedObject, its documentation, and the surrounding nullness annotations. Mark the return type as @Nullable and run the project's relevant checks to confirm static analysis no longer reports the erroneous non-null result.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- security
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Quiet
- Clarity
- Clearly specified
- Newbie friendliness
- 78/100