Hi can anyone give an answer? Found this in cryptology book: ii. Assuming that your computing platform can perform 1 billion divisions per second (and assuming that the rest of the program takes negligible time), what is the largest number of digits an inputted integer n could have so that the program could be guaranteed to execute in less than one minute? iii. Under the assumption of part (ii), how long could it take for the program to check whether a 100-digit integer is prime?

Member Avatar
Member Avatar
+0 forum 1

Hello, I got implementation of Data Encryption Standard implementation in java (internet code) but the only part that I cannot understand is the S-Box which shown below. I know how S-Box works but I don't understand this code especially &0x20 and stuffs like that. The S-Box takes a 6 bit word such as 110110 as input. It takes the first and last bits (**1**1011**0**) as row and the inner bits (1**1011**0) as column. Can anyone explain how this code below achieve what the S-Box does. If I want to change the input as a 4-bits word, how does the code …

Member Avatar
Member Avatar
+0 forum 1

I need some help to make AES work with UDP. I keep getting this error. Exception in thread "main" javax.crypto.IllegalBlockSizeException: Input length must be multiple of 16 when decrypting with padded cipher at com.sun.crypto.provider.CipherCore.doFinal(CipherCore.java:750) at com.sun.crypto.provider.CipherCore.doFinal(CipherCore.java:676) at com.sun.crypto.provider.AESCipher.engineDoFinal(AESCipher.java:313) at javax.crypto.Cipher.doFinal(Cipher.java:2087) at AES.decrypt(AES.java:31) at EchoServer.main(EchoServer.java:26) It seems that upon receiving the UDP AES encrypted message from client, it has problem decrypting due to the byte[] which is being received from UDP transmission. I have also no idea whether am I doing it the right way. What I mean is that, is there any way which I can do to ensure that …

Member Avatar
+0 forum 0

"Active cracking" means indirectly changing a plaintext message so that it becomes a totally different, plaintext message that says something totally different but still makes sense, by creating a brand new encryption key that is applied to the ciphertext itself and changes the ciphertext rather than the original plaintext. I know this can be done without ever knowing the original plaintext message because you don't have to decrypt the ciphertext in order to change it, but can it be done without ever determining the original encryption key, or do you have to determine the original encryption key in order to …

Member Avatar
+0 forum 0

Hi Friends, I have PSKC XML file.. That contains my Salt/Key,IV(Initialization Vector),Encrpted Data,password also. Now, I am trying to Do Password Based Encyption and Decryption Using PBEWITHSHA1AND128BITAES-CBC-BC Algorithm. It works,If i generate salt and IV randomly. But,it fails to work,if i dont generate it randomly... Instead of generating Salt and IV randomly.. i am using my own salt,IV,password and everything.. Here is my code.... import java.security.NoSuchAlgorithmException; import java.security.NoSuchProviderException; import java.security.SecureRandom; import java.security.Security; import java.security.spec.InvalidKeySpecException; import javax.crypto.Cipher; import javax.crypto.SecretKey; import javax.crypto.SecretKeyFactory; import javax.crypto.spec.IvParameterSpec; import javax.crypto.spec.PBEKeySpec; import javax.crypto.spec.SecretKeySpec; import org.bouncycastle.crypto.PBEParametersGenerator; import org.bouncycastle.crypto.digests.SHA256Digest; import org.bouncycastle.crypto.engines.AESEngine; import org.bouncycastle.crypto.generators.PKCS12ParametersGenerator; import org.bouncycastle.crypto.modes.CBCBlockCipher; import org.bouncycastle.crypto.paddings.PKCS7Padding; import org.bouncycastle.crypto.paddings.PaddedBufferedBlockCipher; …

Member Avatar
Member Avatar
+0 forum 5

I need some project ideas on cryptography/information system securoty for a simple and small project.......

Member Avatar
Member Avatar
+0 forum 1

Please i am now in my final year and decided to do a project in Network Security.But presently i am blank as to what doable projects i can research on.Please Help suggest projects which you think is good and doable.Post here or email me on *** [email]frank.kent@yahoo.com[/email] ***

Member Avatar
Member Avatar
+0 forum 8

i have to decrypt a frame on my server. encrypted frame is coming from client device through GPRS on socket.encryption is done with "TripleDes" and with a given key.same algorithm and key i am using n server side. frame is a combination of Hex and Ascii String. problem is when i decrypt this frame i get an error : javax.crypto.IllegalBlockSizeException: Input length must be multiple of 8 when decrypting with padded cipher and when i pad my byte array with zeros i get an error : javax.crypto.BadPaddingException: Given final block not properly padded following is my code : byte[] key …

Member Avatar
Member Avatar
+0 forum 2

I am working to take c code from an academic paper and edit. I am studying cryptographic algorithms. I have ran the following code, but I am having a little difficulty understanding two things. First, the program uses unsigned long ints. When they are added or subtracted, I don't get the values I would expect. For example: P, Q, My sum by hand, sum using c 01100011010100011110000110110111 10111001011110010011011110011110 00011100110010110001100101010101 00011100110010110001100[COLOR="Red"]0[/COLOR]010101[COLOR="Red"]10[/COLOR] I understand that unsigned long int is 32 bit and that the addition is mod 2^32, but I thought the last carry bit when you add to the left by …

Member Avatar
Member Avatar
+0 forum 4

What is the best approach we can follow while trying to solve a cipher text without a key? I searched over web but was unable to find some good method.... Plz help guys...

Member Avatar
Member Avatar
+0 forum 3

i am doing a project in which i simulate symmetric encryption in routers.so hav to store secret keys for mac encryption in a symmetric matrix.how do i do it?????????should i convert them to strings and then store strings in a matrix??????? URGENT HELP NEEDED!!!!!!!!!

Member Avatar
Member Avatar
+0 forum 8

Hello, does anybody know why below 2 echoes are providing diferent results [CODE] <?php $in ='textInputTest'; $key ='AAAABBBBAAAABBBB'; $iv ='AAAABBBB'; echo base64_encode(mcrypt_encrypt(MCRYPT_RC2, $key, $in, MCRYPT_MODE_CBC, $iv)) .":"; echo base64_encode(openssl_encrypt($in, 'rc2-cbc', $key, true, $iv)); ?> [/CODE] (results: I6twEgBKQEaNzeP0nMeLJg== : 7bJWXaOJf31WYcJn2UcDrg==) ... second result is the same that C# and some other tools provides. So OpenSSL conform my needs... But I still want to know why MCRYPT result is different because the same encryption mode, cypher, key and init-vector used...

Member Avatar
Member Avatar
+0 forum 2

Hi, Absolute newbie to cryptography. I'm looking for C++ open source code (to be compiled on Windows, Mac, linux), for doing the following: 1. Generate private+public keys (need not run on all platforms). 2. (server side) Adding a digital signature to an XML document using a private key. 3. (client side) Verifying signature using the matching public key. I envisage the signed XML to look like this: [CODE] <root> <creditcard> <number>19834209</number> <expiry>02/02/2002</expiry> </creditcard> </root> <Signature> WvZUJAJ/3QNqzQvwne2vvy7U5Pck8ZZ5UTa6pIwR7GE+PoGi6A1kyw== </Signature> [/CODE] Thanks in advance, Gil.

Member Avatar
Member Avatar
+0 forum 2

hey i am trying to implement the diffie hellman key exchange algorithm in matlab. my problem is this: the program works just fine for numbers upto 5 digits, but after that it just sort of stops working. thing is i need to deal (multiply,exponentiation,modular arith etc.) with really big numbers in the range of 192 to 1024 bits. so how exactly do i get matlab to give me an output for this? or should i be looking at another implementation? p.s. i know that it can be done, but i am highly frustrated about the lack of specific information on …

Member Avatar
+0 forum 0

Hi, I want to know if we can use javascript for file encryption (not text). If yes then how? Any help appreciated.

Member Avatar
Member Avatar
+0 forum 3

So, first off lemme explain what a substitution code is in case you don't know. In cryptography, it's a system by which one letter is replaced with another predetermined letter. For example, if "I" turns to "E", and "F" turns to "V", the word "If" would be written as "Ev". I'm wondering if it's possible to write a program in C++ which does this in a string for me. I'm a heavy beginner, as in only a few weeks of classes, but I think I'm getting closer and closer, but I also think I'm missing some key component knowledge. If …

Member Avatar
Member Avatar
+0 forum 2

Hi, I'm attempting to generate a new cipher key using a string that was negotiated earlier on. On running the code I get the error: Exception in thread "main" java.lang.IllegalArgumentException: Missing argument at javax.crypto.spec.SecretKeySpec.<init>(DashoA13*..) at shared.Cryptographer.makeCipher(Cryptographer.java:254) at client.Main.main(Main.java:60) Java Result: 1 the code is as follow: [CODE] public void makeCipher(String key, int Skeytype){ try { byte[] salt = new byte[16]; for (int i = 0; i < 16; i++) salt[i] = (byte) 0; PBEKeySpec password = new PBEKeySpec(key.toCharArray(), salt, 1000, 128); SecretKeyFactory factory = SecretKeyFactory.getInstance("PBKDF2WithHmacSHA1"); PBEKey pbekey = (PBEKey) factory.generateSecret(password); SecretKey encKey = new SecretKeySpec(pbekey.getEncoded(), ciphtype); if(Skeytype == 0 || …

Member Avatar
Member Avatar
+0 forum 1

the rc6 paper say this [CODE]Key schedule for RC6-w/r/b Input: User-supplied b byte key preloaded into the c-word array L[0; ..., c - 1] Number r of rounds Output: w-bit round keys S[0; ..., 2r + 3] Procedure: S[0] = Pw for i = 1 to 2r + 3 do S[i] = S[i - 1] + Qw A = B = i = j = 0 v = 3* max[c, 2r + 4] for s = 1 to v do A = S[i] = (S[i] + A + B)<<<3 B = L[j] = (L[j] + A + B)<<<(A + B) …

Member Avatar
+0 forum 0

can anyone tell me what i did wrong with the decryption part of this code? ive been looking at it for some time now (while working on other related stuff), and i cant seem to find the problem with it. its getting really retarded, on my part [B]and this is not homework! i do not take any computer classes at all. im doing this because i want to, but im stuck, and cant find any answers[/B] [CODE]# Tiny Encryption Algorithm def add(value1, value2): return (value1 +value2)%(2**32) def makehex(value,size=8): value = hex(value)[2:] if value[-1] == 'L': value = value[0:-1] while len(value)<size: …

Member Avatar
Member Avatar
+0 forum 2

Any suggestions for cryptography projects?

Member Avatar
Member Avatar
-3 forum 5

The End.