Skip to content

Replace unsafe String casts with instanceof check in AtlassianOauthConfig #6875

Open
srikanthpadakanti wants to merge 1 commit into
opensearch-project:mainfrom
srikanthpadakanti:fix-unsafe-oauth2-cast-6874
Open

Replace unsafe String casts with instanceof check in AtlassianOauthConfig #6875
srikanthpadakanti wants to merge 1 commit into
opensearch-project:mainfrom
srikanthpadakanti:fix-unsafe-oauth2-cast-6874

Conversation

@srikanthpadakanti
Copy link
Copy Markdown
Collaborator

@srikanthpadakanti srikanthpadakanti commented May 21, 2026

Description

Replace unsafe (String) casts on PluginConfigVariable.getValue() in AtlassianOauthConfig with a resolveStringValue() helper that uses instanceof check and toString() fallback.

Issues Resolved

Resolves #6874
#6874

Check List

  • [ X ] New functionality includes testing.
  • New functionality has a documentation issue. Please link to it in this PR.
  • [ X ] New functionality has javadoc added
  • [ X ] Commits are signed with a real name per the DCO

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@srikanthpadakanti srikanthpadakanti changed the title Replace unsafe String casts with instanceof check in AtlassianOauthCo… Replace unsafe String casts with instanceof check in AtlassianOauthConfig May 21, 2026
@srikanthpadakanti srikanthpadakanti force-pushed the fix-unsafe-oauth2-cast-6874 branch from 690c7a9 to 704acd2 Compare May 21, 2026 02:21
…nfig

Signed-off-by: Srikanth Padakanti <srikanth_padakanti@apple.com>
@srikanthpadakanti srikanthpadakanti force-pushed the fix-unsafe-oauth2-cast-6874 branch from 704acd2 to 1a43376 Compare May 21, 2026 02:33
@srikanthpadakanti
Copy link
Copy Markdown
Collaborator Author

Hello @dlvenable Please review

@srikanthpadakanti
Copy link
Copy Markdown
Collaborator Author

Hello @kkondaka Can you please take a look at it when you get a chance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Fix unsafe PluginConfigVariable casts in AtlassianOauthConfig

2 participants