Skip to main content

resolve_credential_for_server

Function resolve_credential_for_server 

Source
pub fn resolve_credential_for_server(
    server_key: &str,
) -> Result<Option<ServerCredential>>
Expand description

Resolve a credential for a server key, trying common key variations.

The credential store key may include a scheme prefix (e.g. http://host:port) while the remote URL parser strips scheme prefixes (producing just host:port). This function tries the bare key first, then common scheme-prefixed variants.