Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

feat(remote): add support for policy.json allow/deny#1013

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
TerryHowe wants to merge1 commit intooras-project:main
base:main
Choose a base branch
Loading
fromTerryHowe:feature-policy-json

Conversation

@TerryHowe
Copy link
Member

@TerryHoweTerryHowe commentedOct 6, 2025
edited
Loading

scottrigby and benoittgt reacted with thumbs up emoji
@codecov
Copy link

codecovbot commentedOct 6, 2025
edited
Loading

Codecov Report

❌ Patch coverage is90.43478% with22 lines in your changes missing coverage. Please review.
✅ Project coverage is 82.91%. Comparing base (983aba6) to head (39e9cd5).

Files with missing linesPatch %Lines
...istry/remote/internal/configuration/requirement.go91.30%6 Missing and 4 partials⚠️
registry/remote/internal/configuration/policy.go83.33%4 Missing and 4 partials⚠️
...egistry/remote/internal/configuration/evaluator.go95.45%2 Missing⚠️
registry/remote/repository.go91.30%1 Missing and 1 partial⚠️
Additional details and impacted files
@@            Coverage Diff             @@##             main    #1013      +/-   ##==========================================+ Coverage   80.59%   82.91%   +2.31%==========================================  Files          64       67       +3       Lines        6121     5009    -1112     ==========================================- Hits         4933     4153     -780+ Misses        864      523     -341- Partials      324      333       +9

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report?Share it here.

🚀 New features to boost your workflow:
  • ❄️Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@TerryHoweTerryHoweforce-pushed thefeature-policy-json branch 2 times, most recently from2c3dc9a tof782b54CompareOctober 6, 2025 19:23
Copy link
Contributor

CopilotAI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Pull Request Overview

This PR adds comprehensive support for the containers-policy.json format, enabling image access control policies based on allow/deny rules. The implementation includes policy management, evaluation, and integration with repository operations.

Key changes:

  • Implements policy evaluation with support for insecure accept, reject, and signature verification requirements (placeholders)
  • Adds policy integration to Repository struct with enforcement in Fetch, Push, and Resolve operations
  • Provides comprehensive test coverage including unit tests, integration tests, and edge case handling

Reviewed Changes

Copilot reviewed 10 out of 10 changed files in this pull request and generated 3 comments.

Show a summary per file
FileDescription
registry/remote/repository.goAdds Policy field and checkPolicy method integration
registry/remote/repository_policy_test.goTests policy enforcement in repository operations
registry/remote/policy/policy.goCore policy management with load/save/validation
registry/remote/policy/evaluator.goPolicy evaluation engine for image access decisions
registry/remote/policy/requirement.goPolicy requirement types and JSON marshaling
registry/remote/policy/policy_test.goComprehensive policy functionality tests
registry/remote/policy/requirement_test.goTests for requirement validation and types
registry/remote/policy/edge_cases_test.goEdge case and error condition testing
registry/remote/policy/example_test.goExample usage and documentation tests
docs/policy.mdDocumentation for the policy package

Tip: Customize your code reviews with copilot-instructions.md.Create the file orlearn how to get started.

@shizhMSFTshizhMSFT changed the titleFeature add support for policy.json allow/denyfeat: add support for policy.json allow/denyOct 10, 2025
@shizhMSFTshizhMSFT changed the titlefeat: add support for policy.json allow/denyfeat(remote): add support for policy.json allow/denyOct 10, 2025
@TerryHoweTerryHoweforce-pushed thefeature-policy-json branch 2 times, most recently from94ca447 to5d442efCompareOctober 25, 2025 11:19
Signed-off-by: Terry Howe <terrylhowe@gmail.com>
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

Copilot code reviewCopilotCopilot left review comments

@sajayantonysajayantonyAwaiting requested review from sajayantonysajayantony is a code owner

@shizhMSFTshizhMSFTAwaiting requested review from shizhMSFTshizhMSFT is a code owner

@SteveLaskerSteveLaskerAwaiting requested review from SteveLaskerSteveLasker is a code owner

@WwwsylviaWwwsylviaAwaiting requested review from WwwsylviaWwwsylvia is a code owner

At least 1 approving review is required to merge this pull request.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

1 participant

@TerryHowe

[8]ページ先頭

©2009-2025 Movatter.jp