|
|
C programming, need help..
Hi,
I'm Siti Zarina from Malaysia. Currently I involve in a research
project on Advanced Encryption Standard (AES).
I'm not really good in C/C++ programming. I need some advice on how to
represent the finite field GF(2^8) operations (such as addition,
inversion, multiplication) in binary representation in C language.
Another thing is how to represent the pseudocode for generating
multiplicative inverse below:
remainder[1] = f(x)
remainder[2] = a(x)
auxiliary[1] = 0
auxiliary[2] = 1
i = 2
do while remainder[i] <> 1
i = i + 1
remainder[i] = remainder(remainder[i-2] / remainder[i-1])
quotient[i] = quotient(remainder[i-2] / remainder[i-1])
auxiliary[i] = quotient[i] * auxiliary[i-1] + auxiliary[i-2]
inverse = auxiliary[i]
For AES, the f(x) = x^8 + x^4 + x^3 + x + 1.
Consideration and help is greatly appreciated.
Thank you.
Regards.
Siti Zarina
[ See http://www.gotw.ca/resources/clcm.htm for info about ]
[ comp.lang.c++.moderated. First time posters: Do this! ]
|
|
0
|
|
|
|
Reply
|
watija (10)
|
3/14/2005 9:02:22 AM |
|
Tiza Naziri wrote:
> Hi,
>
> I'm Siti Zarina from Malaysia. Currently I involve in a research
> project on Advanced Encryption Standard (AES).
>
> I'm not really good in C/C++ programming. I need some advice on how to
> represent the finite field GF(2^8) operations (such as addition,
> inversion, multiplication) in binary representation in C language.
<snip>
C and C++ are quite different languages. A natural implementation of
an algorithm in C++ may well not be valid C code. If you need C
code, this is not the place to ask.
--
Ben Hutchings
Having problems with C++ templates? Your questions may be answered by
<http://womble.decadentplace.org.uk/c++/template-faq.html>.
[ See http://www.gotw.ca/resources/clcm.htm for info about ]
[ comp.lang.c++.moderated. First time posters: Do this! ]
|
|
0
|
|
|
|
Reply
|
Ben
|
3/14/2005 9:34:15 PM
|
|
"Tiza Naziri" <watija@yahoo.com> wrote in message
news:1110770293.226111.62950@g14g2000cwa.googlegroups.com...
> Hi,
>
> I'm Siti Zarina from Malaysia. Currently I involve in a research
> project on Advanced Encryption Standard (AES).
Hello
There are many C implementations of AES on the web (from very verbose to
very speed-optimized) . Browsing the code would give you many hints.
Also try searching under 'rijndael' .
Greetings
Marcin
[ See http://www.gotw.ca/resources/clcm.htm for info about ]
[ comp.lang.c++.moderated. First time posters: Do this! ]
|
|
0
|
|
|
|
Reply
|
Marcin
|
3/15/2005 8:34:17 PM
|
|
|
2 Replies
164 Views
(page loaded in 0.062 seconds)
Similiar Articles: Shading/hatching contourplot - comp.soft-sys.matlabHello, I am making lots of (filled) contourplots and instead of filling certain regions with a color I want to fill them with some shading/hatching... translations of creat() and write() to ISO C - comp.unix ...Need help writing a simple C function - comp.programming ..... comp.lang.fortran... _binding, so the linker must see a C function ... Thank you guys for the help. [ita] FMP - Evuoto() or IsEmpty function and Multiple field - comp ...Need help writing a simple C function - comp.programming ... Need Help: FMPro calculations - Case & IsEmpty - comp ... [ita] FMP - Evuoto() or IsEmpty function and ... how to read bios version using C/C++ - comp.unix.programmer ...I need to get the BIOS version using a C program. According to SMBIOS - specification it is present at ... fault when I try to access this memory location. Please help ... Socket Programming using C++ in Matlab - comp.soft-sys.matlab ...I have a C++ code for doing the socket programming. I need to know how to compile the C++ file in Matlab. In the help file I came across the need for ... Beginner for MPI programming - comp.parallel.mpiHello all, I'm a beginner to MPI Programing in C. Need some help in this regard. I found that, MPI also has datatypes. But not getting why thes... Compiler warnings assoc. with 'fileno' being deprecated on Windows ...See online help for details. c:\program files\microsoft visual studio 8\vc\include\stdio.h(688 ... If you need more "predictable" help or need help for earlier versions of ... Help, can't draw in GIMP. probably some button I pushed?! - comp ...... it, that would be awesome. Using Gimp 2.0.1, gtk 2.2.4 on Windows XP Need help ... GIMP desktop shortcut to include --ignore-wintab in the Target Section: "C:\Program ... HELP! I want to program the steepest descent method? - comp.sys ...Hi fellas: I really need to program the "stepeest descent ... Thanks for your help. I am new to IDL so ... explain.html ) as an external C program for IDL. Creating a library of a Model using TLC - comp.soft-sys.matlab ...But in the end I need a library which I can include into another c-program. So, I think I need to ... Please, can someonde help me. Thanks in Advance Julian C programming.com - Learn C and C++ Programming - Cprogramming.comA website designed to help you learn C or C++. Understandable C and C++ programming tutorials, compiler reviews, source code, tips and tricks. Calculator In C Programming! I Need Help! - C And C++ | Dream.In.CodeCalculator In C programming! I Need Help!: C Calculator ... How could i do something like this, ideas pls i started the code i have below, but aint what is required ... 7/11/2012 1:16:01 AM
|
|
|
|
|
|
|
|
|