# The Panama Cryptographic Function

Dec98: The Panama Cryptographic Function

## The Panama Cryptographic Function

### By Joan Daemen and Craig Clapp

Dr. Dobb's Journal December 1998

```<b>(a) </b>
for(i=0 ; i<8 ; i++) { p[i] = input[i]; }
<b>(b) </b>
for(i=0 ; i<8 ; i++) { p[i] =b[4] [i]; }
<b>
(c)</b>
for(i=0 ; i<17 ; i++) { r[i] = a[i] ^ (a[(i+1)%17] | ~a[(i+2)%17] ); }
for(i=0 ; i<17 ; i++) { s[i] = r[(7*i)%17] <<< ((i*(i+1)/2 )%32); }
for(i=0 ; i<17 ; i++) { t[i] = s[i] ^ s[(i+1)%17] ^ s[(i+4)%17] ; }
A[0] = t[0] ^ 0x00000001 ;
for(i=0 ; i<8 ; i++) { A[(i+1)%17] = t[(i+1)%17 ] ^ p[i]; }
for(i=0 ; i<8 ; i++) { A[(i+9)%17] = t[(i+1)%17 ] ^ b[16][i]; }

<b>(d)</b>
for(i=0 ; i<8 ; i++) { z[i] = a[i]; }
```

### More Insights

 To upload an avatar photo, first complete your Disqus profile. | View the list of supported HTML tags you can use to style comments. | Please read our commenting policy.

# First C Compiler Now on Github

The earliest known C compiler by the legendary Dennis Ritchie has been published on the repository.

# HTML5 Mobile Development: Seven Good Ideas (and Three Bad Ones)

HTML5 Mobile Development: Seven Good Ideas (and Three Bad Ones)

# Building Bare Metal ARM Systems with GNU

All you need to know to get up and running... and programming on ARM

# Amazon's Vogels Challenges IT: Rethink App Dev

Amazon Web Services CTO says promised land of cloud computing requires a new generation of applications that follow different principles.

# How to Select a PaaS Partner

Eventually, the vast majority of Web applications will run on a platform-as-a-service, or PaaS, vendor's infrastructure. To help sort out the options, we sent out a matrix with more than 70 decision points to a variety of PaaS providers.

More "Best of the Web" >>