Module eradius_lib

Data Types

attribute_list()

attribute_list() = [{eradius_dict:attribute(), term()}]

authenticator()

authenticator() = <<_:128>>

command()

command() = request | accept | challenge | reject | accreq | accresp | coareq | coaack | coanak | discreq | discack | discnak

salt()

salt() = binary()

secret()

secret() = binary()

Function Index

ascend/3
decode_attribute/5
decode_request/2
decode_request/3
decode_request_id/1
decode_value/2
del_attr/2
encode_attribute/3
encode_reply/1Convert a RADIUS reply to the wire format.
encode_request/1Convert a RADIUS request to the wire format.
encode_value/2
get_attr/2
get_attributes/1
make_addr_info/1
pad_to/2pad binary to specific length See http://www.erlang.org/pipermail/erlang-questions/2008-December/040709.html
printable_peer/2
random_authenticator/0
salt_decrypt/3
salt_encrypt/4
scramble/3
set_attr/3
set_attributes/2
timestamp/0
timestamp/1
zero_authenticator/0

Function Details

ascend/3

ascend(SharedSecret::secret(), RequestAuthenticator::authenticator(), X3::binary()) -> binary()

decode_attribute/5

decode_attribute(WholeBin::binary(), Radius_request::#radius_request{}, Attribute::#attribute{}, Pos::non_neg_integer(), Decoder_state::#decoder_state{}) -> #decoder_state{}

decode_request/2

decode_request(Packet::binary(), Secret::secret()) -> #radius_request{} | {bad_pdu, list()}

decode_request/3

decode_request(Packet::binary(), Secret::secret(), Authenticator::authenticator()) -> #radius_request{} | {bad_pdu, list()}

decode_request_id/1

decode_request_id(Req::binary()) -> {0..255, binary()} | {bad_pdu, list()}

decode_value/2

decode_value(X1::binary(), Type::eradius_dict:attribute_prim_type()) -> term()

del_attr/2

del_attr(Req, Id) -> any()

encode_attribute/3

encode_attribute(Radius_request::#radius_request{}, Attribute::#attribute{}, Value::term()) -> binary()

encode_reply/1

encode_reply(Radius_request::#radius_request{}) -> binary()

Convert a RADIUS reply to the wire format. This function performs the same task as encode_request/2, except that it includes the authenticator substitution required for replies. The Message-Authenticator MUST be used in Access-Accept, Access-Reject or Access-Chalange replies that includes an EAP-Message attribute [RFC 3579].

encode_request/1

encode_request(Radius_request::#radius_request{}) -> {binary(), binary()}

Convert a RADIUS request to the wire format. The Message-Authenticator MUST be used in Access-Request that include an EAP-Message attribute [RFC 3579].

encode_value/2

encode_value(X1::eradius_dict:attribute_prim_type(), V::term()) -> binary()

get_attr/2

get_attr(Radius_request::#radius_request{}, Id::eradius_dict:attribute_id()) -> eradius_dict:attr_value() | undefined

get_attributes/1

get_attributes(Radius_request::#radius_request{}) -> attribute_list()

make_addr_info/1

make_addr_info(X1::{term(), {inet:ip_address(), integer()}}) -> atom_address()

pad_to/2

pad_to(Width, Binary) -> any()

pad binary to specific length See http://www.erlang.org/pipermail/erlang-questions/2008-December/040709.html

printable_peer/2

printable_peer(X1::inet:ip4_address(), Port::eradius_server:port_number()) -> io_lib:chars()

random_authenticator/0

random_authenticator() -> authenticator()

salt_decrypt/3

salt_decrypt(SharedSecret::secret(), RequestAuthenticator::authenticator(), X3::binary()) -> binary()

salt_encrypt/4

salt_encrypt(Salt::salt(), SharedSecret::secret(), RequestAuthenticator::authenticator(), PlainText::binary()) -> binary()

scramble/3

scramble(SharedSecret::secret(), RequestAuthenticator::authenticator(), X3::binary()) -> binary()

set_attr/3

set_attr(Radius_request::#radius_request{}, Id::eradius_dict:attribute_id(), Val::eradius_dict:attr_value()) -> #radius_request{}

set_attributes/2

set_attributes(Radius_request::#radius_request{}, NewAttrs::attribute_list()) -> #radius_request{}

timestamp/0

timestamp() -> erlang:timestamp()

timestamp/1

timestamp(Units) -> any()

zero_authenticator/0

zero_authenticator() -> authenticator()


Generated by EDoc