All Downloads are FREE. Search and download functionalities are using the official Maven repository.

Resources.FitNesseRoot.PlugIns.RadiusFixture.UserGuide.GenericPacket.Script.ExtendDictionary.wiki Maven / Gradle / Ivy

The newest version!
---
Test
---
!***> definitions
!define REQUEST { {{{Unknown (254), ID 0
NAS-Identifier: foo.bar.org
Framed-Protocol: PPP
Custom-String: my-custom-string
Custom-Integer: 1234
Custom-Octets: 0x00ab00
Custom-Date: 1634311572
Custom-Ipaddr: 1.2.3.4
Custom-Ipv6addr: 2001:8d0:200:640b:0:0:0:1
Custom-Ipv6prefix: 2001:8d0:200:640b:0:0:0:0/64
Vendor-Specific: vendor ID 3000
  Custom-Vendor-String: my-custom-vendor-string
Vendor-Specific: vendor ID 3000
  Custom-Vendor-Integer: 9234}}} }

!define RESPONSE { {{{Unknown (254), ID 0
NAS-Identifier: foo.bar.org
Framed-Protocol: PPP
Custom-String: my-custom-string
Custom-Integer: 1234
Custom-Octets: 0x00ab00
Custom-Date: 1634311572
Custom-Ipaddr: 1.2.3.4
Custom-Ipv6addr: 2001:8d0:200:640b:0:0:0:1
Custom-Ipv6prefix: 2001:8d0:200:640b:0:0:0:0/64
Vendor-Specific: CustomVendor (3000)
  Custom-Vendor-String: my-custom-vendor-string
Vendor-Specific: CustomVendor (3000)
  Custom-Vendor-Integer: 9234}}} }
*!
!2 Extend Dictionary in RADIUS Fixture Script Mode
Following examples show how to extend Dictionary in RADIUS Communication. The suggested method is ''Scenario Table''.

!3 Extend Dictionary in Table Header
RADIUS Dictionary can be extended providing a custom dictionary into the table header constructor map.

|script               |radius client fixture|!{dictionary:${CUSTOM_DICTIONARY}}     |
|load radius generic endpoint                                                       |
|set packet type      |254                                                          |
|set request attribute|NAS-Identifier       |with value|foo.bar.org                 |
|set request attribute|Framed-Protocol      |with value|PPP                         |
|set request attribute|Custom-String        |with value|my-custom-string            |
|set request attribute|Custom-Integer       |with value|1234                        |
|set request attribute|Custom-Octets        |with value|0x00ab00                    |
|set request attribute|Custom-Date          |with value|1634311572                  |
|set request attribute|Custom-Ipaddr        |with value|1.2.3.4                     |
|set request attribute|Custom-Ipv6addr      |with value|2001:8d0:200:640b:0:0:0:1   |
|set request attribute|Custom-Ipv6prefix    |with value|2001:8d0:200:640b:0:0:0:0/64|
|set request attribute|Custom-Vendor-String |with value|my-custom-vendor-string     |
|set request attribute|Custom-Vendor-Integer|with value|9234                        |
|check                |send packet          |Unknown (254)                          |
|check                |request              |${REQUEST}                             |
|check                |response             |${RESPONSE}                            |

!3 Extend Dictionary in Table Row
RADIUS Dictionary can be extended providing a custom dictionary into the ''extend dictionary'' table row.

|script               |radius client fixture                                        |
|load radius generic endpoint                                                       |
|set packet type      |254                                                          |
|extend dictionary    |${CUSTOM_DICTIONARY}                                         |
|set request attribute|NAS-Identifier       |with value|foo.bar.org                 |
|set request attribute|Framed-Protocol      |with value|PPP                         |
|set request attribute|Custom-String        |with value|my-custom-string            |
|set request attribute|Custom-Integer       |with value|1234                        |
|set request attribute|Custom-Octets        |with value|0x00ab00                    |
|set request attribute|Custom-Date          |with value|1634311572                  |
|set request attribute|Custom-Ipaddr        |with value|1.2.3.4                     |
|set request attribute|Custom-Ipv6addr      |with value|2001:8d0:200:640b:0:0:0:1   |
|set request attribute|Custom-Ipv6prefix    |with value|2001:8d0:200:640b:0:0:0:0/64|
|set request attribute|Custom-Vendor-String |with value|my-custom-vendor-string     |
|set request attribute|Custom-Vendor-Integer|with value|9234                        |
|check                |send packet          |Unknown (254)                          |
|check                |request              |${REQUEST}                             |
|check                |response             |${RESPONSE}                            |

!3 Extend Dictionary in ''Scenario Table''
RADIUS Dictionary can be extended providing a custom dictionary into the ''dictionary'' table row.

|scenario         |my generic packet request with dictionary|
|load radius generic endpoint                               |
|extend dictionary|${CUSTOM_DICTIONARY}                     |

|script               |radius client fixture                                        |
|my generic packet request with dictionary                                          |
|set packet type      |254                                                          |
|set request attribute|NAS-Identifier       |with value|foo.bar.org                 |
|set request attribute|Framed-Protocol      |with value|PPP                         |
|set request attribute|Custom-String        |with value|my-custom-string            |
|set request attribute|Custom-Integer       |with value|1234                        |
|set request attribute|Custom-Octets        |with value|0x00ab00                    |
|set request attribute|Custom-Date          |with value|1634311572                  |
|set request attribute|Custom-Ipaddr        |with value|1.2.3.4                     |
|set request attribute|Custom-Ipv6addr      |with value|2001:8d0:200:640b:0:0:0:1   |
|set request attribute|Custom-Ipv6prefix    |with value|2001:8d0:200:640b:0:0:0:0/64|
|set request attribute|Custom-Vendor-String |with value|my-custom-vendor-string     |
|set request attribute|Custom-Vendor-Integer|with value|9234                        |
|check                |send packet          |Unknown (254)                          |
|check                |request              |${REQUEST}                             |
|check                |response             |${RESPONSE}                            |




© 2015 - 2025 Weber Informatics LLC | Privacy Policy