"use strict";function createRegistryAuthMiddleware(e){return(t,r,s)=>{const i=t.method.toUpperCase();if("GET"===i||"HEAD"===i)return void s();const o="string"==typeof t.headers.authorization?t.headers.authorization:void 0;if(!o||!o.startsWith("Bearer "))return void r.status(401).json({error:"UNAUTHORIZED"});o.slice(7)===e?s():r.status(401).json({error:"UNAUTHORIZED"})}}Object.defineProperty(exports,"__esModule",{value:!0}),exports.createRegistryAuthMiddleware=createRegistryAuthMiddleware;