LATEST ARTICLES

XXTEA block cipher implement in PHP and Javascript

xxtea php

In cryptography, Corrected Block TEA (often referred to as XXTEA) is a block cipher designed to correct weaknesses in the original Block TEA. Source: https://en.wikipedia.org/wiki/XXTEA We provide some function implement in PHP and Javascript: PHP <?php /** * @author www.Tutorialspots.com * @copyright 2017 */ /** * Corrected Block TEA implement in PHP * @param $v: n word data vector * @param $key: 4 word key ...

XTEA block cipher implement in PHP and Javascript

xtea php

In cryptography, XTEA (eXtended TEA) is a block cipher designed to correct weaknesses in TEA. The cipher's designers were David Wheeler and Roger Needham of the Cambridge Computer Laboratory, and the algorithm was presented in an unpublished technical report in 1997 (Needham and Wheeler, 1997). It is not subject to any patents. Like TEA, XTEA is a 64-bit block Feistel...

Test vectors TEA

test vectors for tea

Read first: TEA block cipher implement in PHP and Javascript We provide some test vectors for TEA: Test vector| Hex Test vector | Test key | Hex Test key |...

TEA block cipher implement in PHP and Javascript

tea php

In cryptography, the Tiny Encryption Algorithm (TEA) is a block cipher notable for its simplicity of description and implementation, typically a few lines of code. It was designed by David Wheeler and Roger Needham of the Cambridge Computer Laboratory; it was first presented at the Fast Software Encryption workshop in Leuven in 1994, and first published in the proceedings...

Spritz stream cipher implement in PHP and Javascript

spritz php

Ron Rivest and Jacob Schuldt have proposed replacing RC4 with an improved and slightly modified version dubbed Spritz. <?php /** * @author www.Tutorialspots.com * @copyright 2017 */ function spritz($str, $key) { //Key-scheduling algorithm (KSA) for ($s = array(), $i = 0; $i < 256; $i++) $s = $i; ...

RC4+ stream cipher implement in PHP and Javascript

rc4 plus php

RC4+ is a modified version of RC4 with a more complex three-phase key schedule (taking about 3× as long as RC4, or the same as RC4-drop512), and a more complex output function which performs four additional lookups in the S array for each byte output, taking approximately 1.7× as long as basic RC4. We provide some function of RC4+ stream...

VMPC stream cipher implement in PHP and Javascript

vmpc php

VMPC (Variably Modified Permutation Composition) is a stream cipher similar to the well known and popular cipher RC4 designed by Ron Rivest. It was designed by Bartosz Zoltak, presented in 2004 at the Fast Software Encryption conference. VMPC is a modification of the RC4 cipher. We provide some function of VMPC stream cipher implement in PHP and Javascript PHP <?php /** * @author...

RC4A cipher implement in PHP and Javascript

rc4a php

RC4A is one of RC4 variants. Souradyuti Paul and Bart Preneel have proposed an RC4 variant, which they call RC4A. We provide some function implement of RC4A cipher in PHP and Javascript: PHP <?php /** * @author www.Tutorialspots.com * @copyright 2017 */ function rc4a($str, $key) { //Key-scheduling algorithm (KSA) for ($s = array(), $i = 0; $i < 256;...

RC4 implementation in PHP and Javascript

rc4 implementation in php

In cryptography, RC4 (Rivest Cipher 4 also known as ARC4 or ARCFOUR meaning Alleged RC4, see below) is a stream cipher. We provide some function RC4 in PHP and Javascript PHP: /** * @author www.Tutorialspots.com * @copyright 2012 */ /* Stream cipher CR4 */ function rc4($str, $key) { //Key-scheduling algorithm (KSA) for ($s = array(), $i = 0;...

PHP: how to convert ip address to binary string or hex string

hex2ip

With pure PHP, you can convert an IPv4 address to long with the function ip2long, but how to convert an Ipv6 address to long. You can't do this in the 32bits system. You only convert an ip address to binary string or hex string with some method we provide below: <?php /** * @author www.tutorialspots.com * @copyright 2016 **/ function ip2bin($ip)...