DanielLeens opened a new pull request, #13271:
URL: https://github.com/apache/seatunnel/pull/13271

   ## Contribution
   
   Yes, I am contributing to Apache SeaTunnel.
   
   ## Summary
   
   Update `DES_ENCRYPT` / `DES_DECRYPT` in SQL/Zeta and Calcite to use a 
per-value initialization vector and an explicitly versioned ciphertext 
representation.
   
   - Generate a fresh eight-byte IV for each encryption call.
   - Return `STDES1:` followed by Base64 encoding of `IV || ciphertext`.
   - Recognize the new representation during decryption while retaining reads 
of historical Base64 ciphertext.
   - Reject malformed versioned payloads and stop returning unencrypted input 
when encryption fails.
   - Document the output-format and error-handling changes in the English and 
Chinese migration notes and Calcite function reference.
   
   ## Compatibility and migration
   
   Function signatures, null handling and password interpretation remain 
unchanged. Existing ciphertext remains readable, but older runtimes cannot read 
the new output. Upgrade readers before writers, including consumers outside 
SeaTunnel, and allow sufficient storage space for the prefix and IV.
   
   The encrypted output is intentionally non-deterministic and must not be used 
as a stable join, deduplication or replay key. Existing stored ciphertext is 
not rewritten automatically. DES remains a legacy algorithm; the new 
representation does not change its key size or add ciphertext authentication.
   
   ## Tests
   
   Added regression coverage for repeated plaintext encryption, legacy 
ciphertext, malformed versioned payloads, empty/Unicode/block-boundary values, 
and actual Calcite SQL execution with repeated rows and literal inputs. Updated 
the previous deterministic-output assertion.
   
   Verified locally on JDK 11.0.27:
   
   - Spotless formatting and `git diff --check`: passed.
   - Focused DES/Zeta/Calcite tests: 25 passed.
   - Entire `seatunnel-transforms-v2` unit-test suite: 1,963 tests, 0 failures, 
0 errors, 0 skipped.
   - Module and dependency reactor `verify -DskipTests`: all 11 projects passed.
   
   The Maven wrapper bootstrap was unavailable in the local checkout, so the 
installed Maven was used. Dependencies were packaged and installed before 
running the transform module alone to resolve shaded dependency classes. Tests 
using localhost mock servers ran with local execution permission. Docker E2E 
and whole-repository verification have not been run.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to