Skip to content

add setOutputPassword for HSLFSlideShow and HWPFDocument#1050

Merged
pjfanning merged 7 commits intoapache:trunkfrom
pjfanning:copilot/add-tests-for-biff8encryptionkey
Apr 23, 2026
Merged

add setOutputPassword for HSLFSlideShow and HWPFDocument#1050
pjfanning merged 7 commits intoapache:trunkfrom
pjfanning:copilot/add-tests-for-biff8encryptionkey

Conversation

@pjfanning
Copy link
Copy Markdown
Member

  • Add tests for commit eacd5f9 (MainExtractorFactory password support)
  • Add setOutputPassword to HSLFSlideShow and HSLFSlideShowImpl
  • Add setOutputPassword to HWPFDocumentCore
  • Refactor HSLFSlideShowEncrypted:
    • Add updateEncryptionRecord(records, password) overload that takes password directly
    • Deprecate the old updateEncryptionRecord(records) (which reads from Biff8EncryptionKey)
  • Refactor HSLFSlideShowImpl.write():
    • Remove Biff8EncryptionKey manipulation (set/restore)
    • Determine output password locally (_outputPasswordBiff8EncryptionKey fallback, constructor password NOT used)
    • Call new updateEncryptionRecord(records, password) overload directly
    • Updated javadoc and defensive copy in setOutputPassword()
  • Refactor HSLFSlideShow.setOutputPassword(): updated javadoc
  • Fix HWPFDocumentCore.updateEncryptionInfo():
    • Remove _password (constructor password) from the fallback chain
    • Chain is now: _outputPasswordCharsBiff8EncryptionKey.getCurrentUserPassword()
    • Updated javadoc and defensive copy in setOutputPassword()

Copilot AI and others added 2 commits April 22, 2026 10:51
…Show/HWPFDocument

Agent-Logs-Url: https://github.com/pjfanning/poi/sessions/c3e970da-a269-4a43-b2ce-1cabede8daee

Co-authored-by: pjfanning <11783444+pjfanning@users.noreply.github.com>
…add updateEncryptionRecord overload

Agent-Logs-Url: https://github.com/pjfanning/poi/sessions/badb4a65-eb67-4c7f-af19-c30f8f2b20aa

Co-authored-by: pjfanning <11783444+pjfanning@users.noreply.github.com>
@pjfanning pjfanning marked this pull request as draft April 22, 2026 20:23
@pjfanning pjfanning marked this pull request as ready for review April 22, 2026 23:13
@pjfanning pjfanning merged commit e6a04b4 into apache:trunk Apr 23, 2026
1 check passed
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.

2 participants