This is a piece of work created to help with identifying and understanding the beginner
levels of IT Security and encryption techniques
The largest value that this Calculator can calculate is 9007199254740991 due to standard
Javascript restrictions
For the Large Number Calculator (with no
limits apart from the speed that your computer takes to process) you can visit the other page Big Integer
Calculator
*The Big Number Calculator also has more calculators and examples to work with...
Receiver has all values including secret λ and μ values
Tools:
*If you want to manually enter the values, enter them in the inputs instead of
clicking on compute button
Encode:
Get λ (Lambda) value:
Calculate K Value :
Calculate μ (Mu) Value :
Encrypt Message (c) :
Decode:
Decrypt Message (M) :
Project Details:
CryptoCalculator
Created by: @sqeel404
Description
This project was put together during the mid semester break to help identify and understand the underlying
concepts, formulas and principles within the Cryptography classes.
This is the original site, it holds the standard base calculations in javascript, however due to the javascript large
number limitations it can not hadle substantially large numbers, so it ony contains the basic concepts and tools,
such as:
Modulus calculation
Power modulus calculations
Modulus Inverse Calculations
Random Prime number
Random number
Elgamal Encryption
Elgamal Decryption
Paillier Encryption
Paillier Decryption
The javascript files have been broken up into specific types of calculations to help users identify how the
formulas are calculated in the javascript language. These are using basic javascript mathematic calculations in
order to help other users understand the underlying concepts.
If you want to view the specific javascript calculations, here are the links to the speicic javascript files. All
the methods have comments explaing what they do, how they function and the values required for them to function:
This is a child of the original site, it has the same initial calculations, however this version uses the BigInteger.js
javascript library which allows uses to do calculations on substantially large numbers. Due to this, further
examples have been added as they can use substantially larger numbers for their calculations.
The tools so far are:
Modulus calculation
Power modulus calculations
Modulus Inverse Calculations
Random Prime number
Random number
Convert Number to Binary
Convert Binary to Number
Elgamal Encryption
Elgamal Decryption
Paillier Encryption
Paillier Decryption
Elgamal Homomorphic encryption/decryption and
multiplication of secret numbers
*The Paillier version for secret addition of numbers will be added shortly for reference.
The javascript files for these are also split up based on type of calculations to help users understand the
concepts, however as they use the BigInteger.js library, the code is not using standard mathematic formulas. The
BigInteger.js library can be found at: https://github.com/peterolson/BigInteger.js and
it also lists a full explanation and examples of the library methods in the readme on the page.
If you want to view the specific javascript calculations, here are the links to the speicic javascript files. All
the methods have comments explaing what they do, how they function and the values required for them to function: