Forum Discussion
Irule to insert source IP in UDP payload
- Oct 09, 2019
when CLIENT_ACCEPTED { set payloadLength [UDP::payload length] set address [IP::client_addr] set addressLength [ string length $address ] UDP::payload replace $payloadLength $addressLength $address }
You can also use the CLIENT_DATA and SERVER_DATA events and take a look at https://clouddocs.f5.com/api/irules/UDP__payload.html
when CLIENT_ACCEPTED {
set payloadLength [UDP::payload length]
set address [IP::client_addr]
set addressLength [ string length $address ]
UDP::payload replace $payloadLength $addressLength $address
}
You can also use the CLIENT_DATA and SERVER_DATA events and take a look at https://clouddocs.f5.com/api/irules/UDP__payload.html
so if we need to insert source-IP in TCP payload, we just need to replace UDP with TCP in given irule ?
when CLIENT_ACCEPTED {
set payloadLength [TCP::payload length]
set address [IP::client_addr]
set addressLength [ string length $address ]
TCP::payload replace $payloadLength $addressLength $address
}
Recent Discussions
Related Content
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com