I was curious to learn if there is a simple method/algorithm through which I can obtain a generator g for a 20-digit prime integer to implement in Elgamal cryptosystem.
Finding generator g for a 20-digit prime integer I'm Elgamal
582 views Asked by Zod At
1
There are 1 answers
Related Questions in CRYPTOGRAPHY
- Secure Messaging Implementation in C#
- How to verify JWS (x5c chain) is signed by apple using Jose
- How to Safely Use Crypto.subtle Property for Local Testing Without Security Risks?
- OpenSSL3.0 RSA Signature Verification in C
- npm install tulind in my crypto server side
- how i need place arg in code for funtion send?
- Mbed TLS: in-place en-/decryption for OAEP doesn't seem to work
- Cannot test cryptographic performance using crypto_aesni_mb
- Installation Private Blockchain
- Encountered this error while implementing NTT cpp code: terminate called after throwing an instance of 'std::bad_alloc' what(): std::bad_alloc
- Cryptography Notion - Diffie-Hellmann
- Hash password with another password
- How to convert CryptAcquireContext to .NET 8 using System.Security.Cryptography methods
- Error "Cannot find module 'crypto'" in WalletConnect module
- Why do some cryptographic signature npm packages (like superdilithium) convert text to an array of integers before signing?
Related Questions in DIFFIE-HELLMAN
- Cryptography Notion - Diffie-Hellmann
- PACE PIN Generic Mapping implementation in c#
- ECDH C# key exchange ( get the shared secret beetween the two party)
- Decrypting TLS_DHE_WITH_AES_256_CBC_SHA256
- Deriving DH shared secret
- Load Public Key Byte as DH Key
- How do I create and connect anonymous-DH TLS sockets with Python and securely authenticate over them without possibility of credential forwarding?
- How do I get the common secret for numbers that are less than modulo in the modulo function?
- Implementing Diffie-Hellman in python. Shared secret keys aren't getting matched
- Websites using DHE Diffie-Hellman key exchange
- How migrate key reading DH-Pem in Delphi-Indy-SSL to C# on .NET 6.0?
- Issue with implementing X25519 from RFC 7748
- Trying to guess p and q from N by using Diffie-Hellman cycles algorithm, too slow BigInteger.Pow approach
- How is the numeric value obtained through Diffie-Hellman key exchange used?
- Oakley group 2 prime number contains pi, an irrational number
Related Questions in ELGAMAL
- Python library to encrypt files with a GnuPG v1.2.1 Elgamal key
- Speed up exponential elgamal decryption
- Finding generator g for a 20-digit prime integer I'm Elgamal
- Python: Large float arithmetic for El Gamal decryption
- ElGamal import a big prime number
- How to Make Encryption (c1, c2) Tuple Explicit using Bouncy Castle ElGamal and javax.crypto.Cipher
- How can I encrypt/decrypt content with ELGAMAL PGP algorithm by using Bouncy Castle Java library with Certificates persisted in JKS
- TypeError: Cannot read property 'elGamal' of undefined
- El Gamal encryption of clear Text (not numbers) not woring
- Elgamal BN_exp() operation get stuck
- ElGamal Signature: Re-Calculate private key with Python
- ElGamal homomorphic multiplication using Bouncy Castle
- Why RSA is said to be faster than ElGamal Encryption?
- Encrypt AES secret key with Elliptic Curve ElGamal
- El Gamal with Elliptic Curve in Java
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
Popular Tags
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
The best way to do this is pick your prime such that finding a generator is easy. Often the best way is to find a prime p such that q=2p+1 is also prime. Then in the multiplicative group of order q, elements will have order 2p, p, 2 or 1. Most will have order 2p, so just pick a number g and check that g^2 and g^p are not 1, then it will have order 2p and thus be a generator of the group.
If the prime is given (say q), then the order of the group will be q-1 and you will need to factorise q-1 into prime factors (which is not always easy). Then when picking your candidate g, you need to check that g^x (for x ranging through all combinations of prime factors that are less than q-1) is not 1, then you'll know that g has order q-1 and is a generator. Which is why, if you can pick your prime q, it's easier to make sure that q-1 factorises nicely into just two primes.