Commit Graph

20 Commits

Author SHA1 Message Date
tomas.kracmar 5b761d8d56 fix(Extract-NTHashes): add HMAC-SHA256 to the AES export (breaking format bump to ELY2)
Protect-FileWithAES used AES-256-CBC with no integrity check. A wrong
passphrase or corrupted/tampered ciphertext just decrypts to garbage
(or an unhelpful padding exception) instead of being detected.

Derives a second 32-byte key from the same PBKDF2 stream (the AES key
and HMAC key are sequential, non-overlapping ranges of one
Rfc2898DeriveBytes instance) and computes HMAC-SHA256 over
magic+salt+iv+ciphertext (encrypt-then-MAC), appended as a trailer.
Bumped the format magic from 'ELY1' to 'ELY2' so old and new files
are distinguishable.

This is a breaking change for whatever external tooling decrypts
these exports (this repo only ever encrypts - decryption happens on
a separate air-gapped machine per the README's FAQ) - documented the
new layout and the break in the README.

Verified with an isolated round-trip test (function extracted,
dot-sourced, paired with a hand-written decrypt+HMAC-verify): correct
passphrase round-trips cleanly, a wrong passphrase is rejected via
HMAC mismatch, and a single flipped ciphertext byte is also rejected
via HMAC mismatch, in all cases before any AES decryption is
attempted.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-07-29 12:10:04 +02:00
tomas.kracmar 65e451413e Release v2.4.5: detect explicit Deny ACEs in replication permission check
Test-ReplicationPermissions previously only scanned Allow ACEs, so an
explicit Deny on the DCSync extended rights (common in hardening
baselines that Deny a broad group and Allow only named service
accounts) was invisible to the pre-flight check: it reported
"verified" while Get-ADReplAccount still failed with "Replication
access was denied". The check now flags exactly which right is
blocked and by which identity's Deny ACE.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-07-29 11:49:14 +02:00
tomas.kracmar 1d98b908c6 Release v2.4.4: check schema NC replication rights for DSInternals 7.0
DSInternals 7.0 fetches the AD schema via DRS (GetNCChanges) before
replicating accounts, so the schema NC has its own ACL requirement.

- Test-ReplicationPermissions now validates rights on both the
  domain NC and the configuration NC (schema NC inherits from it).
- Updated README with dsacls delegation examples and dual-NC
  least-privilege requirements.
- Improved 'Replication access was denied' error message to name
  both NCs and explain the DSInternals 7.0 change.
- Diagnostic dump now includes SchemaDN.

All versions bumped to unified v2.4.4.
2026-06-15 08:38:04 +02:00
tomas.kracmar ad1db86232 Release v2.2.0: unified versioning and replication permission pre-check
- Unified project versioning (v2.2.0) across all scripts, settings template,
  and documentation. All components now share a single version number.
- Added Test-ReplicationPermissions to Test-WeakADPasswords.ps1 to validate
  the three required AD replication extended rights before DCSync, providing
  clear fail-fast errors when permissions are missing.
- Updated CHANGELOG.md with unified versioning strategy and release history.
- Updated README.md with versioning section and improved troubleshooting docs.
2026-06-09 09:43:43 +02:00
tomas.kracmar 60a7671ceb Fix KHDB password match format handling 2026-03-16 16:38:19 +01:00
Tom Frost 7f1df7b102 Improve weak password test credential diagnostics and docs 2026-02-17 12:40:04 +01:00
tomas.kracmar 7874c0e65b Clarified privileges needed 2025-12-08 16:24:26 +01:00
tomas.kracmar a55ef3713f Bug fixes 2025-11-07 20:33:21 +01:00
tomas.kracmar bda19432e2 Update to prefer PS7 if available 2025-11-07 20:21:03 +01:00
tomas.kracmar 7c2bb65a86 Parallel transfers 2025-11-07 18:14:43 +01:00
tomas.kracmar 4b1b841383 KHDB rework 2025-11-07 15:58:35 +01:00
tomas.kracmar 964e91d20f Fixing handling errors in datasets 2025-10-21 15:34:44 +02:00
tomas.kracmar 05e9358357 Versions bump 2025-10-21 13:42:46 +02:00
tomas.kracmar f7b83e14a5 Updates 2025-10-13 12:39:46 +02:00
tomas.kracmar 2269660984 Update README.md 2024-05-09 13:54:32 +02:00
tomas.kracmar bc8947bd50 Updated README for detailed report explanation. 2024-05-09 13:51:13 +02:00
tomas.kracmar 2a34a5ca52 Typo fix 2024-04-12 20:42:07 +02:00
tomas.kracmar 538dde8a5b Version 1.0 2024-03-22 08:35:52 +01:00
tomas.kracmar 81ad45b4fe First commit 2024-03-15 09:25:58 +01:00
tomas.kracmar 8d74a9159b Initial commit 2023-11-24 12:27:44 +00:00