Documentation ¶
Overview ¶
*Notice:* This module is mostly oriented to validate the DDNS credentials. This is mostly a "hack" to validate the current DDNS status.
The functionalities related to update DDNS records are just for testing purposes. No support or enhancement will be provided for this module.
For more information about the API, please refer to: https://dns.he.net/docs.html
*About the API rate limit:* The API enfoces a rate limit based on the requested domain, thus it's only safe to fail one or two times the authentication against the same domain.
This forces us to randomise the domains used during testing.
Index ¶
- func CheckAuth(ctx context.Context, hostname, password string) (bool, error)
- func UpdateIP(ctx context.Context, hostname, password, myip string) (bool, error)
- func UpdateTXT(ctx context.Context, hostname, password, txt string) (bool, error)
- type Client
- type ErrAPI
- type ErrAbuse
- type ErrAuthFailed
- type ErrDDNS
- type ErrField
- type ErrUnknown
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
type ErrAPI ¶
type ErrAPI struct {
// contains filtered or unexported fields
}
ErrAPI is an error that is returned when the http client returns an error.
type ErrAbuse ¶
type ErrAbuse struct { }
ErrAbuse is an error that is returned when too many requests were performed.
type ErrAuthFailed ¶
type ErrAuthFailed struct{}
ErrAuthFailed is an error that is returned when authentication fails.
func (*ErrAuthFailed) Error ¶
func (e *ErrAuthFailed) Error() string
func (*ErrAuthFailed) Unwrap ¶
func (e *ErrAuthFailed) Unwrap() []error
type ErrDDNS ¶
type ErrDDNS struct {
// contains filtered or unexported fields
}
ErrDDNS error is returned when interation against the DDNS endpoint fails.
type ErrField ¶
type ErrField struct {
// contains filtered or unexported fields
}
ErrField an error that is returned when the request is malformed.
type ErrUnknown ¶
type ErrUnknown struct {
// contains filtered or unexported fields
}
ErrUnknown is an error that is returned when the error cause is unknown.
func (*ErrUnknown) Error ¶
func (e *ErrUnknown) Error() string
func (*ErrUnknown) Unwrap ¶
func (e *ErrUnknown) Unwrap() []error