Tcp api reference, Overview, Methods – Brocade Virtual ADX OpenScript API Guide (Supporting ADX v03.1.00) User Manual

Page 29: Os_tcp::src, Chapter 3

Advertising
background image

Brocade Virtual ADX OpenScript API Guide

17

53-1003243-01

Chapter

3

TCP API reference

In this chapter

This chapter contains the following sections:

Overview. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17

Methods . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17

Overview

The OS_TCP module includes the APIs to retrieve the fields in the current TCP header.

The use <package> statement needs to be in the declaration block of the script for methods of that
package to be used.

For example: to use the OS_TCP methods, The OS_TCP package must be declared as follows:

use OS_TCP;

Methods

OS_TCP::src

Description

Returns the source port number of the current packet.

Context

Called in context of TCP and HTTP.

Usage

Can be used to perform load-balancing based on source port number.

Input Parameters

None.

Advertising