Posts

Showing posts from April, 2019

Finite Automata Interview Questions and Answers | Automata Theory Solved MCQ | MCQ

1. According to Noam Chomsky Turing Machine will Accepts ___________. a) Regular Language b) CFL c) CSL d) Recursively Enumerable Language View Answer: D 2. X   à αY | α is the production rule for_____________________ a) Regular grammar b) Context Free Grammar c) Right Linear Grammar d) Left Linear Grammar View Answer: C 3. Context Free grammar is ______________ tuple grammar a) 3 b) 4 c) 2 d) can’t be represented. View Answer: B 4. Type-2 grammar has production rule of the form a) X   à αY | α   where α ε T & X,Y ε V b) X   à Yα | α   where α ε T & X,Y ε V c) X   à α    where α ε (V UT )* & X ε V d) None View Answer: C 5. Generation of language   using specific rule is called_________________ a) Derivation b) Optimization c) Analysis d) None of the mentioned View Answer: A 6. A grammar is said to be ambiguous if there exists _______________________ a) More than one LMD b) More than one RMD c) More

Calculate the message digest of a text using the MD5 algorithm in JAVA | Cryptography

Image
HARDWARE AND SOFTWARE REQUIREMENT: 1. Intel based Desktop PC: - RAM of 512 MB 2. Notepad/Notepad ++ editor 3. Net beans / Eclipse THEORY: Ø   The MD5 hashing algorithm is a one-way cryptographic function that accepts a message of any length as input and returns as output a fixed-length digest value to be used for authenticating the original message. Ø   The MD5 hash function was originally designed for use as a secure cryptographic hash algorithm for authenticating digital signatures(to validate the authenticity and integrity of a message, software or digital document) Ø   MD5 is used for storing securing password in database server.   MD5 generated message digest of 128 bits. SOURCE CODE: import java.security.*; public class MD5 {     public static void main(String[] a) {         try {             MessageDigest md = MessageDigest.getInstance("MD5");             System.out.println("Message digest object info:");             Sy

Calculate the message digest of a text using the SHA-1 algorithm in JAVA | Cryptography

Image
HARDWARE AND SOFTWARE REQUIREMENT: 1. Intel based Desktop PC: - RAM of 512 MB 2. Notepad/Notepad ++ editor 3. Net beans / Eclipse THEORY: Ø   A hash function is a special mathematical function that converts a numerical input value of arbitrary length into another compressed numerical value(fixed length). A hash performs one-way encryption.Values returned by a hash function are called message digest or simply hash values. hash codes or simply hashes. Ø   It is fundamental part of password security, in terms of database storage. A hash function responsible for changing a text password into a more complex set of characters by using more complex operations than a familiar mathematical operation such as multiplication. Ø   Using hashes and  hexadecimal  formats can help those who are storing passwords on a database to confuse hackers. Ø   The Secure Hash Algorithm 1 (SHA-1) is a cryptographic computer security algorithm.SHA-1 produces a 160-bit hash value from the inpu

Search related post on google