| 1 |
package xmpp |
| 2 |
|
| 3 |
import "errors" |
| 4 |
|
| 5 |
var ( |
| 6 |
// ErrMissingHost is returned when the configuration URL has no hostname. |
| 7 |
ErrMissingHost = errors.New("host is required") |
| 8 |
|
| 9 |
// ErrMissingUser is returned when the configuration URL has no auth user. |
| 10 |
ErrMissingUser = errors.New("user is required") |
| 11 |
|
| 12 |
// ErrMissingPassword is returned when the configuration URL has no password. |
| 13 |
ErrMissingPassword = errors.New("password is required") |
| 14 |
|
| 15 |
// ErrMissingTargets is returned when neither to nor rooms is set. |
| 16 |
ErrMissingTargets = errors.New("at least one to or rooms target is required") |
| 17 |
|
| 18 |
// ErrDisableTLSOnXMPPS is returned when disabletls is set on an xmpps:// URL. |
| 19 |
ErrDisableTLSOnXMPPS = errors.New("disabletls is not allowed with xmpps://") |
| 20 |
|
| 21 |
// ErrUnsupportedScheme is returned when the URL scheme is not xmpp or xmpps. |
| 22 |
ErrUnsupportedScheme = errors.New("unsupported URL scheme") |
| 23 |
|
| 24 |
// ErrInvalidUserJID is returned when the auth user is not a valid JID. |
| 25 |
ErrInvalidUserJID = errors.New("user is not a valid JID") |
| 26 |
|
| 27 |
// ErrInvalidRecipientJID is returned when a to= value is not a valid JID. |
| 28 |
ErrInvalidRecipientJID = errors.New("recipient is not a valid JID") |
| 29 |
|
| 30 |
// ErrInvalidRoomJID is returned when a rooms= value is not a valid JID. |
| 31 |
ErrInvalidRoomJID = errors.New("room is not a valid JID") |
| 32 |
|
| 33 |
// ErrAuthenticationFailed is returned when SASL authentication is rejected. |
| 34 |
ErrAuthenticationFailed = errors.New("authentication failed") |
| 35 |
) |