GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Fix double DeleteLocalRef call which results in UB by normanmaurer · Pull Request #1001 · netty/netty-tcnative

Conversation

@normanmaurer

@normanmaurer normanmaurer commented Aug 28, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

Motivation:

A double DeleteLocalRef on the same local reference is present in both the OpenSSL and BoringSSL cert-verify callbacks in sslcontext.c. The NETTY_JNI_UTIL_DELETE_LOCAL macro does not null out the pointer after deleting
, so a second delete on the same stale handle is real UB per the JNI spec — it can corrupt the local-ref table and crash later in an unrelated JNI call.

This regression was introduces by 990751e

Modifications:

Remove deletion of local ref when its already done

Result:

No more UB

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@normanmaurer
Fix double DeleteLocalRef call which results in UB
cb0cc70
Motivation:

A double DeleteLocalRef on the same local reference is present in both the OpenSSL and BoringSSL cert-verify callbacks in sslcontext.c. The NETTY_JNI_UTIL_DELETE_LOCAL macro does not null out the pointer after deleting
, so a second delete on the same stale handle is real UB per the JNI spec — it can corrupt the local-ref table and crash later in an unrelated JNI call.

This regression was introduces by 990751e

Modifications:

Remove deletion of local ref when its already done

Result:

No more UB
@normanmaurer
normanmaurer force-pushed the double_delete_local branch from 86a3c0f to cb0cc70 Compare August 28, 2026 16:50
@normanmaurer normanmaurer changed the title Motivation: Fix double DeleteLocalRef call which results in UB Aug 28, 2026
@normanmaurer normanmaurer added this to the 2.0.83.Final milestone Aug 28, 2026
@normanmaurer

normanmaurer commented Aug 28, 2026

Copy link
Copy Markdown
Member Author

@chrisvest also did add some safety guards in netty/netty-jni-util@5ba8032.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@normanmaurer normanmaurer mentioned this pull request Aug 28, 2026
Update to latest netty-tcnative release netty/netty#17356
Closed
@normanmaurer
normanmaurer merged commit 9c0ab42 into main Aug 28, 2026
17 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@normanmaurer
normanmaurer deleted the double_delete_local branch August 28, 2026 19:02
@normanmaurer normanmaurer mentioned this pull request Aug 28, 2026
Do not delete the authentication method local reference twice #1002
Closed
@dongjoon-hyun dongjoon-hyun mentioned this pull request Sep 4, 2026
[SPARK-59259][BUILD] Upgrade netty-tcnative to 2.0.83.Final apache/spark#58528
Closed
dongjoon-hyun added a commit to apache/spark that referenced this pull request Sep 4, 2026
@dongjoon-hyun
[SPARK-59259][BUILD] Upgrade netty-tcnative to 2.0.83.Final
2a7cfea
### What changes were proposed in this pull request?

This PR aims to upgrade `netty-tcnative` to 2.0.83.Final.

### Why are the changes needed?

To bring the latest bug fixes.
- https://github.com/netty/netty-tcnative/releases/tag/netty-tcnative-parent-2.0.83.Final (2026-08-29)
  - netty/netty-tcnative#1001
- https://github.com/netty/netty-tcnative/releases/tag/netty-tcnative-parent-2.0.82.Final (2026-08-28)
  - netty/netty-tcnative#995
  - netty/netty-tcnative#996
  - netty/netty-tcnative#997
  - netty/netty-tcnative#999

### Does this PR introduce _any_ user-facing change?

No.

### How was this patch tested?

Pass the CIs.

### Was this patch authored or co-authored using generative AI tooling?

Generated-by: Claude Opus 5

Closes #58528 from dongjoon-hyun/SPARK-59259.

Authored-by: Dongjoon Hyun <[email protected]>
Signed-off-by: Dongjoon Hyun <[email protected]>
This was referenced Sep 10, 2026
[fix][sec] Upgrade Netty to 4.2.18 to address several CVEs and bugs apache/pulsar#26514
Merged
[fix][sec][branch-4.x] Upgrade Netty to 4.1.138 to address several CVEs and bugs apache/pulsar#26515
Merged
@normanmaurer normanmaurer mentioned this pull request Oct 30, 2026
jni util 0.0.12 #1039
Closed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

2.0.83.Final

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

1 participant

@normanmaurer
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.