From 54ccf06a7ebdfa5978240c0d358f21bc90829cfd Mon Sep 17 00:00:00 2001 From: Bartosz Spyrko-Smietanko Date: Fri, 2 Aug 2024 13:05:28 +0200 Subject: [PATCH] Add override for manifest signature URL --- .../main/java/org/wildfly/channel/ChannelImpl.java | 10 ++++++++-- .../wildfly/channel/ChannelManifestCoordinate.java | 14 +++++++++++++- .../wildfly/channel/ChannelMetadataCoordinate.java | 11 +++++++++++ .../org/wildfly/channel/v2.1.0/schema.json | 4 ++++ doc/spec.adoc | 3 ++- 5 files changed, 38 insertions(+), 4 deletions(-) diff --git a/core/src/main/java/org/wildfly/channel/ChannelImpl.java b/core/src/main/java/org/wildfly/channel/ChannelImpl.java index 58ba360c..a032df52 100644 --- a/core/src/main/java/org/wildfly/channel/ChannelImpl.java +++ b/core/src/main/java/org/wildfly/channel/ChannelImpl.java @@ -228,7 +228,7 @@ private ChannelManifest resolveManifest(ChannelManifestCoordinate manifestCoordi * * @throws ArtifactTransferException if any artifacts can not be resolved. */ - public List resolveChannelMetadata(List coords, boolean optional) throws ArtifactTransferException { + private List resolveChannelMetadata(List coords, boolean optional) throws ArtifactTransferException { requireNonNull(coords); List channels = new ArrayList<>(); @@ -239,7 +239,13 @@ public List resolveChannelMetadata(List>). *** `url` corresponding to a URL where the manifest file can be found. +*** `signature-url` corresponding to a URL where the signature of the manifest file can be found. * Optional `blocklist` corresponding to the Blocklist artifact. Blocklist is used to define versions of artifacts excluded from a channel. ** One of the following, mutually exclusive fields, used to resolve the Blocklist: *** `maven` corresponds to Maven coordinates of the Blocklist. It's composed of: @@ -247,7 +248,7 @@ The signature file is resolved at the same time as the artifact. If the signatur #### Verifing manifest signatures -If the manifest of a channel is defined as a Maven GA(V), it is treated as any other maven artifact. If it is defined as an URL, the signature file must be available at the same URL with ".asc" suffix. If the signature cannot be resolved, the channel creation must fail. +If the manifest of a channel is defined as a Maven GA(V), it is treated as any other maven artifact. If it is defined as an URL, the signature file must be available at the same URL with ".asc" suffix. Alternatively, a `signature-url` element can be used to provide a location of the signature. If the signature cannot be resolved, the channel creation must fail. #### Public keys