diff --git a/pkg/auth/saml_config_validator.go b/pkg/auth/saml_config_validator.go index 8f6166652..540a1536f 100644 --- a/pkg/auth/saml_config_validator.go +++ b/pkg/auth/saml_config_validator.go @@ -19,6 +19,8 @@ import ( "encoding/pem" "fmt" "net/url" + + pemutil "github.com/getprobo/probo/pkg/crypto/pem" ) type ValidationError struct { @@ -114,7 +116,7 @@ func validateCertificate(certPEM string) error { return fmt.Errorf("cannot parse certificate PEM") } - if block.Type != "CERTIFICATE" { + if block.Type != pemutil.BlockTypeCertificate { return fmt.Errorf("PEM block type must be CERTIFICATE (found: %s)", block.Type) }