Sponsored Content
Top Forums Programming regarding extracting of packet and checking its crc Post 302148123 by madfox on Friday 30th of November 2007 12:45:21 AM
Old 11-30-2007
about the data

hello,

i only need to verify the data after i received it
the packet is of size 144 byte : message 140 byte +crc 4 byte
the messege received is a simple string and the crc send is a hexadecimal and received the same.
now i need to add the string and hexdecimal (so need to convert them both to same format)lets say convert the string to decimal (ascii value ) and hexdecimal to decimal.
and add the both......
then divide it by key .......i get the remainder zero if the message is not corrupted.
should this be the way to check the the packet validation of the data with the crc at the receiver end.
assume that i have received the data in the afore said format

thanking you
 

10 More Discussions You Might Find Interesting

1. Filesystems, Disks and Memory

crc error ? ? ? ? H E L P

there is a message crc error when i install rethat 7.1 what is these message means ? And why is my harddisk drive detected as hdc not hda ?? please do reply if you have any idea or guesses . thanking you all systen config : intel P4 intel 845 256 SD ... (1 Reply)
Discussion started by: immanuelgangte
1 Replies

2. IP Networking

Seeing IP packet

Hi, Is there any way that i can directly take out the IP packet and see its contents. Waiting for your answer .............. Bye (4 Replies)
Discussion started by: manjunath
4 Replies

3. UNIX for Advanced & Expert Users

Does tar do crc checking on a tape or tar file?

Trying to answer a question about whether tar table-of-contents is a good tool for verifying tape data. (1 Reply)
Discussion started by: tjlst15
1 Replies

4. Solaris

invalid compressed data--crc error

I am getting this error when trying to unzip a file.gz . Anyone know how to resolve this ? (3 Replies)
Discussion started by: jxh461
3 Replies

5. Programming

CRC Code

Hi, We have packet of size 144 bytes and wants to genrate & check CRC . Can u give the CRC code ? (3 Replies)
Discussion started by: namrata5
3 Replies

6. Solaris

Can't PowerOn M3000 - Bad Data CRC

Hi, I was working on the M3000 and I did a init 0, powered off the system during the weekend. When I tried to poweron today, the XSCF linux boot image keeps on rebooting and does not go to the login for XSCF access. The "Check" LED is on amber. Tried diagnosing but cant get the system up. Any help... (1 Reply)
Discussion started by: incredible
1 Replies

7. Programming

64-bit CRC Transition To Bytewise Lookup-Table

Good Evening, I started working on the 17x17 4-colouring challenge, and I ran into a bit of an I/O snag. It was an enormous headache to detect the differences in very similar 289-char strings. Eventually, it made more sense to associate a CRC-Digest with each colouring. After learning... (0 Replies)
Discussion started by: HeavyJ
0 Replies

8. SCO

Stop boot system at "Checking protected password and checking subsystem databases"

Hi, (i'm sorry for my english) I'm a problem on boot sco unix 5.0.5 open server. this stop at "Checking protected password and checking subsystem databases" (See this image ) I'm try this: 1) http://www.digipedia.pl/usenet/thread/50/37093/#post37094 2) SCO: SCO Unix - Server hangs... (9 Replies)
Discussion started by: buji
9 Replies

9. AIX

Packet loss coming with big packet size ping

(5 Replies)
Discussion started by: Vishal_dba
5 Replies

10. Shell Programming and Scripting

How to get CRC check sum of files in java EAR file without extracting .jar/.war files to disk.?

unzip -v gives CRC info of each file in a zip(in my case .EAR) file. # unzip -v my-application.ear Archive: my-application.ear Length Method Size Cmpr Date Time CRC-32 Name -------- ------ ------- ---- ---------- ----- -------- ---- 197981 Defl:N 183708 7%... (1 Reply)
Discussion started by: kchinnam
1 Replies
sum(n)							     Cyclic Redundancy Checks							    sum(n)

__________________________________________________________________________________________________________________________________________________

NAME
sum - Calculate a sum(1) compatible checksum SYNOPSIS
package require Tcl 8.2 package require sum ?1.1.0? ::crc::sum ?-bsd | -sysv? ?-format fmt? ?-chunksize size? [ -filename file | -channel chan | string ] _________________________________________________________________ DESCRIPTION
This package provides a Tcl-only implementation of the sum(1) command which calculates a 16 bit checksum value from the input data. The BSD sum algorithm is used by default but the SysV algorithm is also available. COMMANDS
::crc::sum ?-bsd | -sysv? ?-format fmt? ?-chunksize size? [ -filename file | -channel chan | string ] The command takes string data or a file name or a channel and returns a checksum value calculated using the sum(1) algorithm. The result is formatted using the format(n) specifier provided or as an unsigned integer (%u) by default. OPTIONS
-sysv The SysV algorithm is fairly naive. The byte values are summed and any overflow is discarded. The lowest 16 bits are returned as the checksum. Input with the same content but different ordering will give the same result. -bsd This algorithm is similar to the SysV version but includes a bit rotation step which provides a dependency on the order of the data values. -filename name Return a checksum for the file contents instead of for parameter data. -channel chan Return a checksum for the contents of the specified channel. The channel must be open for reading and should be configured for binary translation. The channel will no be closed on completion. -chunksize size Set the block size used when reading data from either files or channels. This value defaults to 4096. -format string Return the checksum using an alternative format template. EXAMPLES
% crc::sum "Hello, World!" 37287 % crc::sum -format 0x%X "Hello, World!" 0x91A7 % crc::sum -file sum.tcl 13392 AUTHORS
Pat Thoyts BUGS, IDEAS, FEEDBACK This document, and the package it describes, will undoubtedly contain bugs and other problems. Please report such in the category crc of the Tcllib SF Trackers [http://sourceforge.net/tracker/?group_id=12883]. Please also report any ideas for enhancements you may have for either package and/or documentation. SEE ALSO
cksum(n), crc32(n), sum(1) KEYWORDS
checksum, cksum, crc, crc32, cyclic redundancy check, data integrity, security, sum COPYRIGHT
Copyright (c) 2002, Pat Thoyts <patthoyts@users.sourceforge.net> crc 1.1.0 sum(n)
All times are GMT -4. The time now is 10:44 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy