Java兼容的cksum功能 [英] Java compatible cksum function

查看:368
本文介绍了Java兼容的cksum功能的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Java中是否有任何库/代码以与unix中的cksum命令一致的方式计算字节流的32位CRC?

Is there any library/code in Java to calculate the 32-bit CRC of a stream of bytes in a way thats consistent with the cksum command in unix ?

推荐答案

Jacksum: http://www.jonelo.de/java/jacksum/ index.html

cksum         algorithm:   POSIX 1003.2 CRC algorithm
              length:      32 bits
              type:        crc
              since:       Jacksum 1.0.0
              comment:     - under BeOS    it is /bin/cksum
                           - under FreeBSD it is /usr/bin/cksum
                           - under HP-UX   it is /usr/bin/cksum and
                             /usr/bin/sum -p
                           - under IBM AIX it is /usr/bin/cksum
                           - under Linux   it is /usr/bin/cksum 

它是开源的。

这篇关于Java兼容的cksum功能的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆