Bruno Rocha
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights
    • Engagement control
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Versions and GitHub Sync Note Insights Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Engagement control Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       owned this note    owned this note      
    Published Linked with GitHub
    Subscribed
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    Subscribe
    # Collection Signing Stories Diagram: https://www.xmind.net/m/jYMP8n [![](https://i.imgur.com/6e94aHT.png)](https://www.xmind.net/m/jYMP8n ) --- :::info **PAH** = Private Automation Hub **CAH** = Cloud Automation Hub **Pulp** = Any topic or work to be developed on pulp upstream ::: ## Pulp Related existing issues: - As a user, I want to able to distinguish signed and unsigned Collections - https://pulp.plan.io/issues/8049 ### Pulp: Create Signature Content Type - **What**: A pulp Content Type (Signature) to enable storing signatures along with its metadata as part of a pulp repository. ```py class ContentSignature(BaseModel): signature_file: FilePath metadata: JsonField content_id: Uuid = OneToOne(T[Collection, Container, ...]) ``` - **Where**: Pulpcore or PulpAnsible (to be discussed) https://pulp.plan.io/issues/9543 ### Pulp: Api to surface signatures :::warning Alternative implementation: Surface the signature only as metadata on content API ::: - **What**: A Viewset + serializer where clients go to fetch signatures for a specific related content e.g: ```bash GET /api/signatures/collections/<id> {"signatures": [{"signature_file": "....", "metadata": "..."}]} ``` - **Where**: Pulpcore or PulpAnsible (to be discussed) - **Depends on**: - Pulp: Create Signature Content Type https://pulp.plan.io/issues/9544 ### Pulp: Import/export must include signatures - **What**: import/export tooling needs to include related signatures for exported content. - **Where**: Pulp Ansible - **Depends on** - Pulp: Create Signature Content Type https://pulp.plan.io/issues/9545 ### Pulp Ansible: Ensure sync takes signatures into account for comparison - **What**: If for example a signature is corrupted on the source system, user may wamt to invalidate the current and create the signature again and then the clients will need to resync to fetch new signatures - **Where**: Pulp Ansible - **Depends on** - Pulp: Create Signature Content Type https://pulp.plan.io/issues/9546 --- ## DOCS EPIC: https://issues.redhat.com/browse/AAH-1031 ### PAH: Document how users can create and configure custom signing service - **What**: Post installation, users can define and configure a Signing service using their own keys and signing script. https://docs.pulpproject.org/pulpcore/workflows/signed-metadata.html# ```bash pulpcore-manager add-signing-service name key sign-script-executable ``` https://issues.redhat.com/browse/AAH-1051 ### PAH: Document how users can manually sign a specific collection using API and UI - **What**: Users may want to sign (or replace the existing signature) of a specific collection. - **Depends on:**: - "API: Create API to sign individual collection" - "UI: Add a `sign` button to the collection view" https://issues.redhat.com/browse/AAH-1052 --- ## Installer ### PAH: Create a default signing service during installation. - **When**: Install post task (pulp_installer.role.galaxy_postinstall) If the user enabled this option on the main install playbook. ```yaml vars: create_default_collection_signing_service: true ``` - **How**: Installer will ship a simple **ASCIIArmoredSigningService** detached signing script and create a signing service named **"ansible-default"** (there will be a container-default in future), the installer will generate the key pairs necessary and based on configuration let those keys to be replaced. - **Where**: Installers (pulp-installer, platform installer, galaxy_ng post install role) https://issues.redhat.com/browse/AAH-1063 ### PAH: Allow definition of which signing service to be used for the whole system - **When**: Install post task (pulp_installer.role.galaxy_postinstall) - **How**: Setting the key `COLLECTION_SIGNING_SERVICE="unique-name"` on `/etc/pulp/settings.py` or as equivalent environment variable. ```bash # setting.py COLLECTION_SIGNING_SERVICE="ansible-default" COLLECTION_SIGNING_ON_APPROVAL=True ``` - **Where**: Galaxy NG User settings https://issues.redhat.com/browse/AAH-1064 ### CAH: Configure rpm-sign based SigningService during installation - **When**: During cloud deployment - **How**: 1. Use `pulpcore-manager add-signing-service` to create a [`rpm-sign`](https://docs.engineering.redhat.com/display/PRODSEC/Signing+Server+User+Guide#SigningServerUserGuide-2.GoldandContainerReadyKeySigning) based signing service 2. And configure `settings.COLLECTION_SIGNING_SERVICE` pointing to that service. - **Where**: Cloud installer https://issues.redhat.com/browse/AAH-1065 --- ## Backend tasks :::danger 🛑 If the signing process fails it fails the whole approval process. ::: ### Create a task that will take an artifact and a signing service and perform the signature process. https://issues.redhat.com/browse/AAH-1054 ### PAH: Sign collections during approval process - **When**: During "approval" task (regardless if is manual or auto approval) or as a subtask in the same task group if a `settings.COLLECTION_SIGNING_SERVICE` is defined. - **How**: 1. Query pulp.**SigningService** to load the **pre-configured signing service** 2. If the collection artifact is stored in an **external storage** it needs to be **downloaded locally in a temporary location**. 3. Invoke the `sign` method on the SigningService to produce the signature Artifact for the collection content. 4. **Store the SignatureContentType** in the same repo where the collection is included. 5. **Approve the collection and move to published repository**. - **Where**: Galaxy NG Approval Task - **Depends on**: - "[Pulp] Create Signature Content Type" https://issues.redhat.com/browse/AAH-1053 ### CAH: Sign collections during certification process - **When**: During Partner Engineer Certification process assuming `settings.COLLECTION_SIGNING_SERVICE` points to a RedHat Signing Server intance. > Everything else is the same as `PAH: Sign collections during approval process` - **Depends on**: - "Pulp: Create Signature Content Type" - CAH: Configure a rpm-sign SigningService during installation https://issues.redhat.com/browse/AAH-1055 --- ## API ### API: Surface collection signature and metadata on collection API - **When**: If collection has signatures associated. - **How**: Query the SignatureArtifact model and include its URL on CollectionSerializer ensure it is present on the APIs consumed by sync clients and ansible-galaxy cli. - **Where**: GalaxyNG API - **Depends on**: - "Pulp: Create Signature Content Type" https://issues.redhat.com/browse/AAH-1057 ### API: Allow filtering signed collections - **How/What**: Add a filter to collection viewset that allows filtering collections having a signature. - **Where**: GalaxyNG API - **Depends on**: - "API: Surface collection signature and metadata on collection API" https://issues.redhat.com/browse/AAH-1058 ### API: Create API to sign individual or multiple collection versions - **What**: User might need to sign individual collection, or to add additional signature or To invalidate a signature on existing collection and providing a new signature. - **How**: Via API user informs the collection to sign, which signing service to use for signature The API spawns a signature task after checking the permissions to perform the signing. ```bash POST /v3/content/collections/<id>/<version>/sign/ -d ''{"signing_service": "ansible-default"}' ``` - **Where**: GalaxyNG API - **Depends on**: - "Pulp: Create Signature Content Type" https://issues.redhat.com/browse/AAH-1056 --- ## UI ### UI: Show a badge on signed collections - **When**: Collection has signature metadata - **How/What**: Add a Verified Badge in collection view ✅ that distinguishes signed collections. - **Where**: Ansible-Hub-UI - **Depends on**: - "API: Surface collection signature and metadata on collection API" https://issues.redhat.com/browse/AAH-1059 ### UI: Allow filtering signed collections - **How/What**: Add dropdown filters to select signed collections only - **Where**: Ansible Hub UI - **Depends on**: - "API: Allow filtering signed collections" https://issues.redhat.com/browse/AAH-1060 ### UI: Add signature download link with collection version download page - **What**: Add a link to download the signature file for a signed collection - **Where: Ansible Hub UI / Collection download page - **Depends on** - API: Surface collection signature and metadata on collection API https://issues.redhat.com/browse/AAH-1061 ### UI: Add a `sign` button to the collection view (for each version) - **What**: Users mught need to sign a specific collection using the UI The UI will show a button on colelction view and this button opens a modal for the user to select a signing service and perform the sign. - **Where: Ansible Hub UI / Collection page - **Depends on** - API: Create API to sign individual collection https://issues.redhat.com/browse/AAH-1062 --- ## Questions - Do we need to surface the Signing Service on API/UI? - Admin user might want to check which signing service is configured without looking to the settings files - Also might be useful to include that info on loggings and status apis.

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password

    or

    By clicking below, you agree to our terms of service.

    Sign in via Facebook Sign in via Twitter Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully