Repository navigation
AUD-01: add Audit module skeleton and solution file - #35
Merged
Merged
Conversation
Add backend/SecurityLab.slnx, the Platform.Audit module with the AddAudit entry point, and Platform.Audit.Tests with DI scope validation tests. Add DI lifetime guidelines for the Audit component.
Bogdan00004
marked this pull request as ready for review
November 2, 2026 18:33
Owner
|
Pregled: AUD-01 pripada timu 12. Osnovni GitHub Actions build prolazi, ali 4 najavljena Audit DI testa nisu pokrenuta u CI. Pre merge-a molimo uključite Platform.Audit.Tests u CI, potvrdite zelen rezultat i ponovo proverite integraciju na najnovijem main. |
…module-skeleton # Conflicts: # backend/Platform.Api/Program.cs
Build and test backend/SecurityLab.slnx, add Platform.Tests to the solution, fail when no test is executed, and always upload the TRX results. Update the DI guidelines for the Identity services now on main.
Collaborator
Author
|
@owlCoder Uključeno: CI sada gradi i testira ceo solution (Audit i Platform.Tests, 46 testova), TRX se čuva i pri padu, a CI pada ako nijedan test nije izvršen. Grana je osvežena na main (e7474c7), konflikt u Program.cs je rešen (dodat samo AddAudit()). CI run: https://github.com/owlCoder/security-lab/actions/runs/41516623911 |
cvetko1e
approved these changes
Nov 2, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Component and requirement IDs
backend/Platform.Audit)Changes
backend/SecurityLab.slnxlisting Platform.Access, Platform.Api, Platform.Audit, Platform.Audit.Tests and Platform.Tests.Platform.Auditproject with the layers Contracts, Domain, Application, Infrastructure and Composition. OnlyAddAudit()exists; it registers nothing yet.Platform.Apireferences Audit and callsAddAudit()afterAddAccessControl()(2 lines inProgram.cs).Platform.Audit.Tests(NUnit) with DI scope validation tests.ci.yml: builds and tests the whole solution (includingPlatform.Tests, previously run by its own step), fails when no test is executed, and uploads the TRX results even when tests fail.docs/components/audit/DI-GUIDELINES.md: proposed service lifetime rules, updated for the Identity services now on main.Program.cs; main's content is kept and onlyAddAudit()is added.Verification
dotnet build backend/SecurityLab.slnx --configuration Releaseanddotnet test backend/SecurityLab.slnx --configuration ReleaseArchitecture and data flow
N/A: this PR adds no data flow or stored data. The component diagram and DFD will accompany the first audit behavior.
Security checks and negative tests
ValidateScopesandValidateOnBuild, both on the container and on the realPlatform.Apihost (now including the Identity registrations).AccessAndAuditRegistrations_PassScopeAndBuildValidation,Host_StartsWithScopeValidation_AndHealthResponds.CaptiveDependency_IsRejectedByValidation,Host_WithCaptiveDependency_FailsToStart.Dependencies
Teststep is replaced by a solution-level run that includesPlatform.Tests(42 tests, all passing).backend/SecurityLab.slnxis also added by PR ACC-04 / ACC-08: KT1 implementacija, bezbednosni model i negativni testovi (ponovljeni PR #20) #25/ACC-04 / ACC-08: KT1 implementacija, bezbednosni model i negativni testovi (ponovljeni PR #21) #26 (restore of ACC-04/ACC-08). Whichever lands second adds its own project to the list.IAuditWriterinPlatform.Api.Services.Identity; how it relates to the future Audit contract is an open question.