Skip to content

[NO-REVIEW] Temporary diagnostics for ChaCha20 on Android#129000

Draft
vcsjones wants to merge 4 commits into
dotnet:mainfrom
vcsjones:android-chacha-diag
Draft

[NO-REVIEW] Temporary diagnostics for ChaCha20 on Android#129000
vcsjones wants to merge 4 commits into
dotnet:mainfrom
vcsjones:android-chacha-diag

Conversation

@vcsjones
Copy link
Copy Markdown
Member

@vcsjones vcsjones commented Jun 4, 2026

Some temporary diagnostics to see if we can learn something from Android's CI.

This is a pull request to troubleshoot something in CI. IT should not be reviewed, as it will NEVER be merged.

Copilot AI review requested due to automatic review settings June 4, 2026 17:04
@vcsjones vcsjones added NO-MERGE The PR is not ready for merge yet (see discussion for detailed reasons) NO-REVIEW Experimental/testing PR, do NOT review it labels Jun 4, 2026
@vcsjones
Copy link
Copy Markdown
Member Author

vcsjones commented Jun 4, 2026

/azp run runtime-android

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 1 pipeline(s).

@dotnet-policy-service
Copy link
Copy Markdown
Contributor

Tagging subscribers to this area: @bartonjs, @vcsjones, @dotnet/area-system-security
See info in area-owners.md if you want to be subscribed.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds additional diagnostics for investigating ChaCha20-Poly1305 AEAD behavior on Android, by emitting extra native-side JNI failure information and augmenting the managed test suite with Android-specific diagnostic logging.

Changes:

  • Add native diagnostics around Cipher.updateAAD, Cipher.update, and Cipher.doFinal failure paths in the Android crypto PAL.
  • Add Android-only test diagnostics (environment + per-case exception details) and wrap an existing tampered-AAD assertion to print extra context when it fails.
Show a summary per file
File Description
src/native/libs/System.Security.Cryptography.Native.Android/pal_cipher.c Adds logging/exception printing around JNI cipher operations to help identify failure modes.
src/libraries/System.Security.Cryptography/tests/ChaCha20Poly1305Tests.cs Adds Android-only diagnostic test/logging to capture environment + exception details for failures.

Copilot's findings

  • Files reviewed: 2/2 changed files
  • Comments generated: 5

@vcsjones
Copy link
Copy Markdown
Member Author

vcsjones commented Jun 4, 2026

/azp run runtime-android

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 1 pipeline(s).

Copilot AI review requested due to automatic review settings June 4, 2026 22:54
@vcsjones vcsjones review requested due to automatic review settings June 4, 2026 22:55
@vcsjones
Copy link
Copy Markdown
Member Author

vcsjones commented Jun 4, 2026

/azp run runtime-android

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 1 pipeline(s).

Copilot AI review requested due to automatic review settings June 5, 2026 01:17
@vcsjones
Copy link
Copy Markdown
Member Author

vcsjones commented Jun 5, 2026

/azp run runtime-android

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 1 pipeline(s).

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot's findings

  • Files reviewed: 6/6 changed files
  • Comments generated: 4

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

Labels

area-System.Security NO-MERGE The PR is not ready for merge yet (see discussion for detailed reasons) NO-REVIEW Experimental/testing PR, do NOT review it

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants