Skip to content

Exception Mapping: 403 FORBIDDEN #55

@ArchILLtect

Description

@ArchILLtect

Summary

Map AccessDeniedException to 403 FORBIDDEN with { error: "FORBIDDEN", message: "..." } in GlobalExceptionHandler.

Motivation / Problem

Ensure consistent error envelopes for authorization failures on delete.

Acceptance Criteria

  • Add @ExceptionHandler(AccessDeniedException.class) mapping to 403 code FORBIDDEN.
  • No change to existing codes or mappings.
  • Negative-path tests assert correct envelope.

Target Release

v0.1.2

Notes / Links

docs/weekly-plan/week-5/week-5-plan-backend.md
docs/weekly-plan/week-5/week-5-plan-issues.md

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:storiesIssues/PRs related to the Stories domain (entity, repository, service, controller, feed, deletion)backendWork related to APIs, services, or controllers.javaPull requests that update java coderoadmapPlanned feature or strategic goal from the project roadmap.securitySecurity-related changes, fixes, or enhancements.type:featureNew feature related to backend types, DTOs, or models.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions