Error Subdomains
Subdomains used to determine how to interpret an error in the kCFStreamErrorDomainSOCKS domain.
Overview
Error codes in the kCFStreamErrorDomainSOCKS domain can come from multiple parts of the protocol stack, many of which define their own error values as part of outside specifications such as the HTTP specification.
To avoid confusion from conflicting error numbers, error codes in the kCFStreamErrorDomainSOCKS domain contain two parts: a subdomain, which tells which part of the protocol stack generated the error, and the error code itself.
Calling CFSocketStreamSOCKSGetErrorSubdomain(_:) returns an identifier that tells which layer of the protocol stack produced the error. This list of constants contains the possible values that this function will return.
Calling CFSocketStreamSOCKSGetError(_:) returns the actual error code that the subdomain describes.