validate_ssl_config

View as MarkdownOpen in Claude

Validate that SSL configuration is complete and the certificate files exist.

Returns

tuple[bool, str | None] — A tuple of (is_valid, error_message). Returns (True, None) when SSL is disabled or when all required files exist.

Example

from signalwire.core.security_config import SecurityConfig
security = SecurityConfig()
is_valid, error = security.validate_ssl_config()
if not is_valid:
print(f"SSL configuration error: {error}")
else:
print("SSL configuration is valid")