blob: f62c96d7231a227bc1f512c2190f07e0ba7cf7c5 [file] [log] [blame]
Pau Espin Pedrol8d8529a2023-10-23 17:20:18 +02001module DIAMETER_rfc5447_Templates {
2
3/* (C) 2023 by sysmocom s.f.m.c. GmbH <info@sysmocom.de
4 * All rights reserved.
5 *
6 * Released under the terms of GNU General Public License, Version 2 or
7 * (at your option) any later version.
8 *
9 * SPDX-License-Identifier: GPL-2.0-or-later
10 */
11
12import from General_Types all;
13import from DIAMETER_Types all;
14import from DIAMETER_Templates all;
15import from Osmocom_Types all;
16import from Misc_Helpers all;
Pau Espin Pedrol009ab6f2024-03-05 13:25:19 +010017import from DIAMETER_rfc4004_Templates all;
18
19/* 4.2.1. MIP6-Agent-Info AVP */
20template (value) GenericAVP ts_AVP_MIP6AgentInfo(template (value) MIPv4_NONE_MIP_Home_Agent_Address addr) := {
21 avp := {
22 avp_header := ts_DIA_Hdr(c_AVP_Code_MIPv6_NONE_MIP6_Agent_Info),
23 avp_data := {
24 avp_MIPv6_NONE_MIP6_Agent_Info := {
25 ts_AVP_MIPHomeAgentAddress(addr)
26 }
27 }
28 }
29}
Pau Espin Pedrol8d8529a2023-10-23 17:20:18 +020030
31/* 4.2.5. MIP6-Feature-Vector AVP */
32const uint64_t DIA_RFC5447_MIP6_Feature_Vector_MIP6_INTEGRATED := hex2int('0000000000000001'H);
33const uint64_t DIA_RFC5447_MIP6_Feature_Vector_LOCAL_HOME_AGENT_ASSIGNMENT := hex2int('0000000000000002'H);
34
35
36/* 4.2.5. MIP6-Feature-Vector AVP */
37template (value) GenericAVP ts_AVP_MIP6FeatureVector(template (value) MIPv6_NONE_MIP6_Feature_Vector inp) := {
38 avp := {
39 avp_header := ts_DIA_Hdr(c_AVP_Code_MIPv6_NONE_MIP6_Feature_Vector),
40 avp_data := {
41 avp_MIPv6_NONE_MIP6_Feature_Vector := inp
42 }
43 }
44}
45template (present) GenericAVP tr_AVP_MIP6FeatureVector(template (present) MIPv6_NONE_MIP6_Feature_Vector inp := ?) := {
46 avp := {
47 avp_header := tr_DIA_Hdr(c_AVP_Code_MIPv6_NONE_MIP6_Feature_Vector),
48 avp_data := {
49 avp_MIPv6_NONE_MIP6_Feature_Vector := inp
50 }
51 }
52}
53
54}