diff --git a/src/main/java/org/sonatype/nexus/plugins/cargo/registry/CargoRegistryFacetImpl.java b/src/main/java/org/sonatype/nexus/plugins/cargo/registry/CargoRegistryFacetImpl.java index 1eab6ed..28d24c0 100644 --- a/src/main/java/org/sonatype/nexus/plugins/cargo/registry/CargoRegistryFacetImpl.java +++ b/src/main/java/org/sonatype/nexus/plugins/cargo/registry/CargoRegistryFacetImpl.java @@ -155,6 +155,7 @@ public void writeConfigJson() throws Exception { JsonObject config = new JsonObject(); config.addProperty("dl", this.getRepository().getUrl() + "/api/v1/crates"); config.addProperty("api", this.getRepository().getUrl()); + config.addProperty("auth-required", true); JsonArray allowedRegistries = new JsonArray(); allowedRegistries.add(new JsonPrimitive(this.config.allowedRegistries.toString())); config.add("allowed-registries", allowedRegistries);