[Function] uri-authority

Package

ystok.uri

Signature

uri-authority uri &optional userinfo => value
(setf uri-authority) value uri => value

Arguments
uri
An instance of the uri structure class.
userinfo
A keyword or any Lisp object specifying what userinfo should be appended to the result;
defaults to :user.
value
A result string (maybe non-simple) or nil.
Values

The authority string combining the host, port and userinfo. The full format is as follows:

user:password@host:port

The result is nil if all the component are nil or prohibited by the userinfo parameter.

Description

One of the following symbols is allowed as the userinfo:

:user
append only the user name;
:password
append both the user and password;
nil
neither append the user nor password

Any other value of userinfo is equivalent to :user.

The setter (setf uri-authority) splits the value specified as the parse-uri does.

RFC3986 deprecates the password component.
"Applications should not render as clear text any data after the first colon ':'. Applications may choose to ignore or reject such data when it is received as part of a reference and should reject the storage of such data in unencrypted form."