import { C as CertOptions, a as CertResult, c as createCertificate, d as downloadCertificate, f as findValidCertificates, r as revokeCertificate, b as revokeExpiredCertificates } from './cert-FehieKeb.cjs'; /** * Generate EC P-256 CSR — used by App Store Connect API (JWT auth). */ declare function generateCSR(): Promise<{ csr: string; privateKey: string; }>; /** * Generate RSA 2048 CSR — required by Apple Developer Portal (session auth). * Matches Fastlane's create_certificate_signing_request which uses RSA 2048. */ declare function generateRSACSR(): { csr: string; privateKey: string; }; /** * PKCS#12 (.p12) packaging — bundles a certificate + private key into an * encrypted .p12 file, which is the format Apple's codesign, xcodebuild, * and Fastlane's cert action all expect for distribution signing. * * Uses node-forge's pkcs12.toPkcs12Asn1 which emits the legacy-compatible * format (3DES + RC2) that Keychain Access, iTMSTransporter, and older * Apple tooling accept. OpenSSL 3's default format requires the -legacy * flag and is not portable; node-forge sidesteps that entirely. */ interface BundleP12Options { /** Certificate: PEM string, or raw DER Buffer as returned by PortalClient.downloadCertificate */ certificate: Buffer | string; /** PEM-encoded RSA private key (as produced by generateRSACSR) */ privateKeyPem: string; /** Password used to encrypt the .p12 */ password: string; /** Friendly name embedded in the bag (shown in Keychain Access) */ friendlyName?: string; } /** * Create a PKCS#12 buffer containing the given cert + private key, * encrypted with `password`. Returns a Buffer suitable for writing to * disk or uploading as a form field. */ declare function bundleP12(options: BundleP12Options): Buffer; type index_BundleP12Options = BundleP12Options; declare const index_CertOptions: typeof CertOptions; declare const index_CertResult: typeof CertResult; declare const index_bundleP12: typeof bundleP12; declare const index_createCertificate: typeof createCertificate; declare const index_downloadCertificate: typeof downloadCertificate; declare const index_findValidCertificates: typeof findValidCertificates; declare const index_generateCSR: typeof generateCSR; declare const index_generateRSACSR: typeof generateRSACSR; declare const index_revokeCertificate: typeof revokeCertificate; declare const index_revokeExpiredCertificates: typeof revokeExpiredCertificates; declare namespace index { export { type index_BundleP12Options as BundleP12Options, index_CertOptions as CertOptions, index_CertResult as CertResult, index_bundleP12 as bundleP12, index_createCertificate as createCertificate, index_downloadCertificate as downloadCertificate, index_findValidCertificates as findValidCertificates, index_generateCSR as generateCSR, index_generateRSACSR as generateRSACSR, index_revokeCertificate as revokeCertificate, index_revokeExpiredCertificates as revokeExpiredCertificates }; } export { type BundleP12Options as B, generateRSACSR as a, bundleP12 as b, generateCSR as g, index as i };