Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

tc-csum(8) [mojave man page]

Checksum action in tc(8)                                               Linux                                              Checksum action in tc(8)

NAME
csum - checksum update action SYNOPSIS
tc ... action csum UPDATE UPDATE := TARGET [ UPDATE ] TARGET := { ip4h | icmp | igmp | tcp | udp | udplite | sctp | SWEETS } SWEETS := { and | or | + } DESCRIPTION
The csum action triggers checksum recalculation of specified packet headers. It is commonly used to fix incorrect checksums after the pedit action has modified the packet content. OPTIONS
TARGET Specify which headers to update: IPv4 header (ip4h), ICMP header (icmp), IGMP header (igmp), TCP header (tcp), UDP header (udp), UDPLite header (udplite) or SCTP header (sctp). SWEETS These are merely syntactic sugar and ignored internally. EXAMPLES
The following performs stateless NAT for incoming packets from 192.0.2.100 to new destination 198.51.100.1. Assuming these are UDP packets, both IP and UDP checksums have to be recalculated: # tc qdisc add dev eth0 ingress handle ffff: # tc filter add dev eth0 prio 1 protocol ip parent ffff: u32 match ip src 192.0.2.100/32 flowid :1 action pedit munge ip dst set 198.51.100.1 pipe csum ip and udp SEE ALSO
tc(8), tc-pedit(8) iproute2 11 Jan 2015 Checksum action in tc(8)

Check Out this Related Man Page

Checksum action in tc(8)					       Linux						  Checksum action in tc(8)

NAME
csum - checksum update action SYNOPSIS
tc ... action csum UPDATE UPDATE := TARGET [ UPDATE ] TARGET := { ip4h | icmp | igmp | tcp | udp | udplite | sctp | SWEETS } SWEETS := { and | or | + } DESCRIPTION
The csum action triggers checksum recalculation of specified packet headers. It is commonly used to fix incorrect checksums after the pedit action has modified the packet content. OPTIONS
TARGET Specify which headers to update: IPv4 header (ip4h), ICMP header (icmp), IGMP header (igmp), TCP header (tcp), UDP header (udp), UDPLite header (udplite) or SCTP header (sctp). SWEETS These are merely syntactic sugar and ignored internally. EXAMPLES
The following performs stateless NAT for incoming packets from 192.0.2.100 to new destination 198.51.100.1. Assuming these are UDP packets, both IP and UDP checksums have to be recalculated: # tc qdisc add dev eth0 ingress handle ffff: # tc filter add dev eth0 prio 1 protocol ip parent ffff: u32 match ip src 192.0.2.100/32 flowid :1 action pedit munge ip dst set 198.51.100.1 pipe csum ip and udp SEE ALSO
tc(8), tc-pedit(8) iproute2 11 Jan 2015 Checksum action in tc(8)
Man Page

8 More Discussions You Might Find Interesting

1. Programming

Disabling IP Checksum Calculation

Hello Friends, I'm constructing the IP Packets by using the RAW Sockets. If I give any value for VER/TTL/Protocol the packet is being transmitted with that particular values. But in case of IP Checksum, I'm always getting the correct checksum value irrespective of the value I give. Can anyone... (5 Replies)
Discussion started by: aamirglb
5 Replies

2. Programming

UDP File Transfer Validation and Checksum

Dear All I have written a client server program for file transmission from one system to other using UDP. Can i use the cksum number in the udp header to validate if the received packet is corrupted or not? If yes, how can i extract the header and validate it.. Also is there any way that... (3 Replies)
Discussion started by: iamcollins
3 Replies

3. Programming

UDP Checksum problem

Hello sir,, i m doing network programming in C could u plzz let me know...at the time of udp checksum calculation does htons() or ntohs() play some role..?? i mean will there be any difference if some values are added in network form and other is in the host form... Thnx 4 ur time.. ... (4 Replies)
Discussion started by: nirucool89
4 Replies

4. UNIX for Dummies Questions & Answers

Log file for icmp requests

I'm not a unix expert so I need to ask what maybe a simple question to some. Is there a log file which records any icmp packets hitting the server? I ask, because I need to verify what the ip is from a server pinging mine. (3 Replies)
Discussion started by: numele
3 Replies

5. Shell Programming and Scripting

Reading and analysing data in a text file

Hi, I have below type of data in a text file in unix. Emp_Name Emp_Dept Raj 101 Amruta 100 Shilpa 100 Rohit 123 Amol 198 Rosh 101 Gaurav 198 Number of employees can be even more. Need a command or a... (2 Replies)
Discussion started by: rajneesh_kapoor
2 Replies

6. Shell Programming and Scripting

adding header in a file

Hi team, In my script i am storing some value in a variable "header". I want to add the header value has header in a file. Please help me on this Thanks in advance, Baski (4 Replies)
Discussion started by: baskivs
4 Replies

7. AIX

Directory csum / cksum

I've created a directory in /tmp/csum-test on AIX 6.1. Then another under AIX 7.1 host called /tmp/csum-test. There is no files in the directories. When I run csum -h SHA1 /tmp/csum-test on AIX 6.1 host it gives me a different value then if I run csum -h SHA1 /tmp/csum-test under the AIX 7.1... (2 Replies)
Discussion started by: Devyn
2 Replies

8. UNIX for Beginners Questions & Answers

Script for creating Control file in UNIX

Delete ---- Original post, restored by mod after being deleted by abhilashnair ---- I have a requirement where, I need to create a control file which will have 3 columns in the header row as below: Filename Count Checksum This above control file has to contain metadata as above... (2 Replies)
Discussion started by: abhilashnair
2 Replies