Documentation ¶
Index ¶
- func GenerateRandomCertificateSerialNumber() (*big.Int, error)
- func ReadEncryptedPEMRSAKeyFile(path string, password []byte) (*rsa.PrivateKey, error)
- func ReadPEMCertificateFile(path string) (*x509.Certificate, error)
- func ReadPEMCertificatesFile(path string) ([]*x509.Certificate, error)
- func ReadPEMRSAKeyFile(path string) (*rsa.PrivateKey, error)
- func SimpleSelfSignedRSAKeypair(cn string, days int) (key *rsa.PrivateKey, cert *x509.Certificate, err error)
- func TopicFromCert(cert *x509.Certificate) (string, error)
- func VerifyFromAppleDeviceCA(c *x509.Certificate) error
- func WriteEncryptedPEMRSAKeyFile(key *rsa.PrivateKey, password []byte, path string) error
- func WritePEMCertificateFile(cert *x509.Certificate, path string) error
- func WritePEMRSAKeyFile(key *rsa.PrivateKey, path string) error
- type PKCS7Verifier
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ReadEncryptedPEMRSAKeyFile ¶
func ReadEncryptedPEMRSAKeyFile(path string, password []byte) (*rsa.PrivateKey, error)
func ReadPEMCertificateFile ¶
func ReadPEMCertificateFile(path string) (*x509.Certificate, error)
func ReadPEMCertificatesFile ¶
func ReadPEMCertificatesFile(path string) ([]*x509.Certificate, error)
func ReadPEMRSAKeyFile ¶
func ReadPEMRSAKeyFile(path string) (*rsa.PrivateKey, error)
func SimpleSelfSignedRSAKeypair ¶
func SimpleSelfSignedRSAKeypair(cn string, days int) (key *rsa.PrivateKey, cert *x509.Certificate, err error)
func TopicFromCert ¶
func TopicFromCert(cert *x509.Certificate) (string, error)
TopicFromCert extracts the push certificate topic from the provided certificate.
func VerifyFromAppleDeviceCA ¶
func VerifyFromAppleDeviceCA(c *x509.Certificate) error
VerifyFromAppleDeviceCA verifies a certificate was signed by Apple's iPhone Device CA. Manually verify the certificate since Go has deprecated verifying SHA1WithRSA x509 certificates.
func WriteEncryptedPEMRSAKeyFile ¶
func WriteEncryptedPEMRSAKeyFile(key *rsa.PrivateKey, password []byte, path string) error
func WritePEMCertificateFile ¶
func WritePEMCertificateFile(cert *x509.Certificate, path string) error
func WritePEMRSAKeyFile ¶
func WritePEMRSAKeyFile(key *rsa.PrivateKey, path string) error
Types ¶
type PKCS7Verifier ¶ added in v1.12.0
type PKCS7Verifier struct { // MaxSkew is the maximum amount of clock skew permitted between the the server time and the pkcs7 signature validity MaxSkew time.Duration }
PKCS7Verifier verifies PKCS7 objects with a configurable clock skew
Directories ¶
Path | Synopsis |
---|---|
Package mdmcertutil contains helpers for requesting MDM Push Certifificates.
|
Package mdmcertutil contains helpers for requesting MDM Push Certifificates. |
Package password provides utilities for creating and verifying macOS passwords for MDM account configuration.
|
Package password provides utilities for creating and verifying macOS passwords for MDM account configuration. |
Package profileutil signs configuration profiles.
|
Package profileutil signs configuration profiles. |
Click to show internal directories.
Click to hide internal directories.