NAME
ppp_oe_tag_dissect - point-to-point over ethernet tag diissect function
SYNOPSIS
opn=ppp_oe_tag_dissect(pkt,offset,tag_end)
PPPOE_TAG_EOL = 0
PPPOE_TAG_SVC_NAME = 257
PPPOE_TAG_AC_NAME = 258
PPPOE_TAG_HOST_UNIQ = 259
PPPOE_TAG_AC_COOKIE = 260
PPPOE_TAG_VENDOR = 261
PPPOE_TAG_RELAY_ID = 272
PPPOE_TAG_SVC_ERR = 513
PPPOE_TAG_AC_ERR = 514
PPPOE_TAG_GENERIC_ERR = 515
DESCRIPTION
HOMEdissect point-to-point over ethernet tags.
prototype is:
1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| TAG_TYPE | TAG_LENGTH |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| TAG_VALUE ... ~
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
references RFC 2516
dissectable are:
end-of-list
service-name
ac-name
host-uniq
ac-cookie
vendor-specific
relay-session-id
service-name-error
ac-system-error
generic-error
funtion accepts three arguments:
pkt is a packet reference containing the whole already dissected packet
offset is the position inside packet to start dissection
tag_end equals offset plus tag length
funtion returns one list:
opn is a list
each item of the list is a dissected tag
this is the tag's prototype: [tag_code,tag_length,(tag_field1,tag_field2,.......,tag_fieldN)]
note: negative tag_code means tag exceeds global tags length