instruction
stringlengths
33
27.2k
Anyone aware of a library that has MA-ABE implemented in any language preferably python? P/S - I hope this is the right place to ask this. Apologies if not, then a redirect will be appreciated
I am asked to answer a question that says: One online book-store wants to grand access to clients regarding their subscription. There are 3 types of subscriptions A , B and C. Customers get access in the subscription type they chose. Also if a book is not listed in the subscription list it's free for all and , every 1...
I am having trouble trying to understand if the function is collision resistant. As I understand it, preimage resistance means that it is hard for an adversary to find two messages that produce the same digest, and second preimage resistance means it is hard for an adversary to find a message that produces the same di...
Bob uses RSA with $p=83$ and $q=103$. His public key is $e=445$. Alice claims that she can calculate Bob's private key without using the definition $d=e^{−1}\bmod φ(n)$? But how?
I'm looking for a PRNG that is deliberately weak, that is, follows a set of rules stochasticly. For example: Encounters a set of bits that is a multiple of X, starts exhibiting bias, or starts to oscillate somewhat. etc... The weaknesses need to both be simple and complex, the experiment would consist of trying to iden...
I am looking for a fast MAC (~few machine instructions) to be used for hash tables with 64-bit public inputs. I can't use SipHash as the hash function will be inlined in too many places and so the code size of SipHash is too large. The sole use of the MAC value will be in hash tables. I want to avoid hash collision ...
As I understand it, reusing a (key, nonce, header data) triple in NORX leaks the XOR of the initial common prefix (but this is zero, so only its length is leaked) the XOR of the first distinct blocks (which is usable by an attacker) Is this all NORX leaks if misused?
Shannon's secrecy can be defined as: $$P_M (M=m) = P_{SK,M}(M=m|E(SK,m)=c)$$ What does $P_M$ means? (same question for $P_{SK,M}$) I know that is the probability space M, M being the messages; I do not really understand why that has to be specified - or in general I don't understand what this means.
In many lattice based cryptosystems, Gaussian distribution is used. Can you explain why only Gaussian distribution is preferred?
I am using double and add method for point multiplication in affine coordinates. How we compute 1PM in double and method? Di Wang said one point multiplication consists of repeated addition and doubling operations, so the calculated time of point multiplication #ADD*1ADD + #DBL*1DBL more less equals 1PM. But when I ca...
There are a lot of good videos on a simple Diffie-Hellman in the internet but unfortunately that is susceptible to the MITM attack. I understand how with DH the two parties are able to calculate a shared secret (shared private key?) So now i am trying to understand the authenticated version, which should be safe from ...
Last fews months, I'm working with homomorphic encryption. Now I am dealing with some computational problems with integers or real-numbers (like arithmetic mean, standard deviation) where division is necessary in homomorphic domain. Is there any practical solution of homomorphic division? I'm also looking for practical...
I want to convert ciphertexts of one encryption scheme to another without decrypting them under the first scheme and then encrypting with the second scheme. For example convert OPE encryption to Paillier without decryption. Does anyone have any idea?
i understand that the purpose of root certificates and CA's is to ensure that the communication parties are who they say they are. But how is the root certificate acquired? Is it not possible that during the acquisition someone is pretending to be the CA and i get a fake root certificate? Thanks!
It seems that the papers I am reading do not talk much about this point. That is how the attributes of a user are authenticated in ABE system. To my understanding, there is an attribute authority (AA) who authenticates the attribute of a user and there is a PKG who generates the private key based on the authenticated a...
Let's say that I have a 4096-bit RSA key and when I sign data, I typically use SHA-512. As far as I understand it, the hash algorithm used to sign/verify a message is specified in the message. If a hash algorithm is susceptible to collisions, then it doesn't matter how large my RSA key is, and signatures can be forged....
From the linear cryptanalysis of SDES, we get a linear equation consisting the K[1, 3] of the round key 1 and 2. From this how will I retrieve the key bit? How do we solve the linear equation we get from the linear cryptanalysis to predict the key bits? The 1 and 3 bits of the round key 1 and 2 are present in the fin...
I have a distributed P2P network. Everyday, I want each node to have a secret which is only valid for that day, while each of the other remaining nodes on the network will be able to calculate the same value. However, I do not want any node to be able to precompute this; for example, if it is Monday I do not want any o...
I have written an encryption implementation using a hash as a cipherstream for demonstration purposes. I know it is slower than more sensible options such as AES but I am interested in several things, which I will list at the bottom of this message. NOTE: I am writing this in a pseudo-language that resembles C++ and us...
Sorry if this is a silly question, but does anyone know if the cryptographic libraries which implement TLS 1.2 for Firefox, Chrome, etc. express a given curve in a canonical form (i.e. one of Weierstrass, Montgomery, or Edwards form for an arbitrary curve) where possible in order to simplify EC arithmetic? I am just st...
I got asked this question today and I didn't know the answer, AES-128 is considered secure, the key size is 2^128, so you would need in average 2^127 tries to break the key. Why does RSA need at least a 1024-bit modulus to be considered secure, If we consider a bruteforce attack on the private exponent, it would take 2...
I am working on a personal project to build a REST authentication system which authenticate clients via three parameters: apikey = example-apikey-34433 hash = examplehash-notarealhash-a34io4oehosseesr timestamp = 2000000000 Every client has a unique apikey and secret key, stored in a database. Hash is a SHA256 hash of...
If a hash function $H$ is collision resistant, are the following two hash functions collision resistant or not? ($||$ is concatenation) $H'(m) = H(H(m)) || H(m)$ $H''(m) = H(m) || H(m)$ My first approach to the problem for the first function is this: by proof of contradiction, I find that there aren't $m_1 \ne m_2$ so...
In many cryptographic protocols design, I have seen the statement 'Choose a Hash function $H:\{0,1\}^x \times G \mapsto Z_p^*$ i.e a hash function which takes as input a binary string of finite length and a random element of some group and outputs an element of multiplicative group of prime field. How could I construc...
There are lots of security algorithms. One of the way to measure security of a cryptography algorithm is to find out its key size. There are many key size of a single algorithm. ECC (Elliptic Curve Cryptography) has 163, 256, 384, 512 etc. RSA has 1024, 3072, 7680, 15360. I found this from here but how can I calculat...
I'm trying to use the 128bit TI_aes implementation on my 16bit microcontroller and I'm having the weirdest issue. Every input where two bytes within a word are identical two nibbles within a byte are identical is successfully encrypting and decrypting but every other input is not working. For example: input: 001122334...
I've noticed that on every site I checked I kept finding the relationship between D-H key size and symmetric encryption equivalent as a table, like: 384 - 56 768 - 80 1792 - 112 2304 - 128 10753 - 256 ... But I never found the formula that is actually used to calculate this equivalence. From what I can see by key size ...
I heard that we can break the Rabin Signature system using chosen-message attack. For a message $M$ that is a quadratic residue modulo $N$, the signature is $x$ such that $x^2 \equiv M \pmod N$. I can't find a message to ask for its signature in order to spoof my message $M$. Any suggestions?
I am currently going through this paper - "A Subexponential Algorithm for the Discrete Logarithm Problem" by Leonard Adleman. On page 56, author mentions that Dixon's algorithm - Asymptotically Fast Factorization of Integers, works in $RTIME (O(2^{O{(\log(q)\log\log(q))}^{1/2}}))$ and on page57, mentions that $r_i, s_...
I know it's generally bad to store password in the clouds, and that I should be using salted-hashed password only. I'm making an application that will authenticate a user (with salted-hash), and then needs to return the credential of all their ip-cameras from the cloud database. For obvious reasons the camera password ...
Surprisingly I have not been able to find an answer to this question on Google. If I have a function that is based on any of the popular hashing algorithms used for password generation, by what percentage/magnitude does the speed change when the string length increases? Assuming the salt is retrieved from the function....
If the input text is divided into a fixed block size for encryption and decryption, what could be the typical block size for RSA algorithm for different size of input like 8 MB, 16 MB, 126 MB and 256 MB?
I am a bit confused on the metrics that can be applied to the output of (deterministic) pseudo-random number generators. I've run output from many RNGs through ENT. The only metrics that really differ between RNGs declared insecure (e.g. Cs rand()) and those declared as CSPRNGS (e.g. Javas SecureRandom) are the Chi-Squ...
If I have 2 true random numbers from atmospheric noise or a different source. Suppose $x= 299$ and $y= 499$. Is it possible to create a bigger number with $x$ to the power of $y$? Can I use different sources like, pressure sensor + light sensor + movement sensor and calculate $x^{y^z}$ for a true random number?
According to wikipedia, if you are using shamir's secret sharing scheme with a field of order $p$, "High values of $p$ are risky because Eve knows that the chance for $f(x)\pmod{p}=f(x)$ increases with a higher $p$". Is this true? It seems wrong.
I am having trouble understanding where the count of "passes" come in. What constitutes a pass in the context of message authentication codes? How are single-pass MACs achieved?
This may be trivial, and may be impossible... this is outside my field but willing to learn. I have a hardware device that accepts a network MAC address (6 bytes of data) like this: 38-60-77-EC-1D-33 and produces a 2-byte hash, like this: F0-9B The same address always produces the same hash, and I can test any address ...
I am currently reading Engineering Security by Peter Gutmann, on page 7 he states: proper mutual authentication is quite different from unilateral authentication in both directions He references What is authentication by Dieter Gollmann which is a transcript of a discussion. The relevant part here is: Next point, ...
I have read a scientific paper which covers some security schemes in mobile ad hoc networks. I don't understand this notation: $$H_0\;\;\;\text{ Mapping }\{0,1\}^*\to \mathbb Z_p^*$$ where $p$ is a prime number. Link to the paper: http://www.hindawi.com/journals/ijdsn/2013/374713/ The notation resides in the table of ...
Can one create a cipher with two meanings? Not two layers, two phrases in the same cipher in the way that it would have a meaning X, for example, if deciphered using Transposition cipher and meaning Y if deciphered with the Playfair chipher. Is it possible?
I would like to send and receive emails between group of people. Is there a way to create it with no need to use some other 3rd party application. Is there a way just to transfer files between 2 people so there won't be any way to decrypt it by any other technology?
For Shamir's Secret Sharing, with a secret of size $n$, instead of having a finite field of order $n$, can we just use Shamir's Secret Sharing $n$ times, once for each bit, using a field of order 2? Is this still as strong as using Shamir's Secret Sharing once with a field of order $n$? Are there any other drawbacks to...
Is there a secret sharing scheme where secrets can be weighted, and that you need a total weight of $1$ to unlock the secret? I know that you could, of course, just figure out every subset that has access to the secret and then do a XOR secret sharing scheme, but that isn't very efficient.
I know that $(k,n)$ can increased to $(k+t,n-s)$ one, by generating a random polynomial $p(x)$ of degree $k+t$ with constant term $0$, and then ordering each agent $a$ to add $p(a_x)$ (where $a_x$ is an agent's public x-coordinate) to their share (if $k$ old shares are compromised, the secret is compromised, but we are...
Is the concept of provably secure hash the same as entropy smoothing hash functions? In the tutorial Sequences of Games: A Tool for Taming Complexity in Security Proofs V. Shoup shows us a proof of semantic security of a hashed ElGamal encryption. In order to get that proof (pag. 9) he put the following condition: we n...
In this paper - "A Subexponential Algorithm for the Discrete Logarithm Problem", author mentions (page 56), For each $p_l^{e_l} | q$ proceed.... $p_l^{e_l}$ is one of the prime factors of $q-1$, and $q$ is a prime. How can any number divide prime? Am I missing something here? Edit1: $q$ is prime, so we can't get any...
The British decrypted the German enigma because they knew that they would repeat the message key twice at the start of every message. Of course, technology to encrypt enigma without the repetition using cribs was developed later but only after it was cracked before. The encryption key for the Enigma messages changed da...
Here is a draft of an article claimed to soon appear in a peer-reviewed conference: Matthew Vilim, Uenry Duwe, Rakesh Kumar, Approximate Bitcoin Mining. It is proposed to simplifying a SHA-256 engine (used in a Proof-of-Work context) in some way, at the expense of quite always having a correct result; and concluded tha...
Are there any fast, secure, one-way, unkeyed almost-pseudorandom permutations? I am looking for something that can hide a MAC, without requiring a secret key and while being much faster than public key crypto. It is important that it is a almost-PRP, not a PRF. By "almost-PRP", I mean "a one-to-one function that is al...
I've see in several places (here or there) the notation $c = (U, V)$ or $c =\langle U, V \rangle$, where $c$ is a ciphertext (to be transmitted). But as both $U$ and $V$ are "key-like". I can't find if the key to be used on the other is $U$ or $V$. From the context, I guessed it means "Encrypt $V$ with $U$ (ie the key)...
I hope not to be asking much, but I have N parties, each one holding a polynomial in with 0-1 coefficients and fixed degree $n-1$. I was wandering if it is possible (I mean feasible) to compute the product of all of these polynomials with an MPC protocol. Actually, for security I would need the result modulo $X^n+1$, s...
Talking about hash functions, I know the hierarchy is as follows: Pre-image resistance Second pre-image resistance Collision resistance Where each property implies the one before it so 2nd pre-image resistance implies pre-image resistance.. But is this also true the other way around? Can we infer from the absence o...
IPSec like strongSwan can be configured to do rekeying after time or bytes transferred or packets transmitted. Is there any recommendations to set those settings? Maybe according to algorithms used?
I thought that access structure and access tree are equivalent but I've read in a paper (page 3) that there are at least three types of access structures : AND gates Access tree LSSS generating matrix I would like to know what is the difference between them, are they equivalent or some of them are more expressive (be...
If I want to have a secret conversation, then I can encrypt it (with OTR etc). However, since big brother watches all communication, sending encrypted data will likely raise flags. Does anyone know of an algorithm to take ciphertext and convert it into harmless looking plaintext? For example, I could take each group of...
Are there any public key encryption algorithms that allows for arbitrary ordering of crypto operations (commutative). That is, given a plaintext $\text{message}_1$, the following operations work to doubly encrypt it: $$\text{message}_2 = \operatorname{encrypt}(\text{message}_1, \text{pub}\_\text{key}_1)$$ $$\text{messa...
i am trying to implement an android app that should "sign" an image, M and a string, S using a private key, K-1 and send the result to a server. for instance the app should be doing {M,S}K-1. the content must remain separate after the server remove the { }K-1 barrier the question is should some sort of file or datatyp...
Suppose that messages $m_1$ and $m_2 \neq m_1$, both known to the attacker, are both MAC'd through Poly1305 with the same key. By chance, these two messages hash to the same value. The attacker knows that $\operatorname{Poly1305}(m_1) = \operatorname{Poly1305}(m_2)$ but not the values of the auth tags (e.g. if they w...
I'm implementing point addition, doubling and scalar multiplication using projective coordinates. I took reference from this link. I have implemented Routine 2.2.6 (ec_double) Routine 2.2.7 (ec_add) Routine 2.2.8 (ec_full_add) Routine 2.2.9 (ecc_full_sub) They all are working and I have verified the results with the ...
We know that 3DES is created with $E_{K_3}(D_{K_2}(E_{K_1}(m)))$ to extend DES's key length. Is it possible to extend it further by repeating this pattern? Perhaps using $E_{K_5}(D_{K_4}(E_{K_3}(D_{K_2}(E_{K_1}(m)))))$ for a 280 bit key.
I am learning about ElGamal signature verification. During the signature generation one has to choose a k such that 1 < k < p − 1 and gcd(k, p − 1) = 1. I am using the notation from the Wikipedia site. Later it is used the inverse of k. I assume this is a modular inverse. Learning materials I have found does not state ...
I found a definition of an exponent operation over the element of $\mathbb{G}$ in this paper (page 4): $$ (g^a)^{\% b} = g ^{a \text{ mod } b}$$ I couldn't understand the rest of the paper (Decrypt primitive). We have $D = g^r g^{M_S} = g^{r + M_S}$ How could they compute: $(D)^{\% M_T}$. In this paper, they have writt...
I am analyzing a system that needs to be at least level 3 FIPS 140-2 compliant. The system may leverage from homomorphic and Zero Knowledge constructs, but, as far as I can see, the algorithms approved for FIPS are the most standard ones: RSA, AES, SHA-*, etc. Is there a similar standard (or an extension to FIPS 140-2)...
After reading up on the one-time pad (OTP) encryption method, I could see how it would offer unbreakable encryption if used properly. Moreover, I looked at how the OTP could be broken if the OTP-key is used on more than one message. What I now wonder is this: if classically you use a Vigenère Square to substitute lette...
i am trying to figure out a man-in-the-middle safe authentication scheme for some devices. I understand that this could be achieved via CA's. But what is unclear to me is how can the authenticity of a device be guaranteed in such a setup. To me it seems that a DEV3 (an imposter) could easily send its public key to the ...
I want to securely store a database table that consists of an account ID and a few columns of sensitive data. The data only has value if it can be associated with the account ID. My thinking is to hash the account ID so it can't be associated with the sensitive data. What hashing algorithm should I used for this situat...
The official NIST publication I saw says for federal applications 3DES with three keys should be used. I have such questions: what does it mean federal? Does it mean for industrial applications that requirement doesn't hold? What security do I get with 2 keys? by two keys I mean when K1==K3, but K2 is different? Is it...
I'm building a Digital Examination system and I'm having problems understanding some concepts in cryptography. I want use to Asymetric Cryptography and my questions are Do I encrypt the entire file? When I do my encryption is it that I should make the entire file encrypted with the private key of the sender of the exa...
Suppose I have a Feistel cipher structure that has $16$ rounds. I come up with $8$ subkeys $k_1,k_2,...,k_8$ to be used for the first $8$ rounds and then assign the rest of the keys so that $k_9=k_8,k_{10}=k_7,...,k_{16}=k_1$. Since the decryption algorithm is the same as encryption, but we reverse the subkeys, would t...
I am trying to find two collisions in SHA1 for the 50 least significant bits. I was wondering if there was a way to efficiently do this without having to brute force all of the possible hash outputs? It seems like trying to look for two same hash outputs is easier than trying to find a message that hashes and matches ...
In the Mac-forge experiment, the adversary is given access to a tag-generation oracle, which generates a tag for each message given by the adversary. The adversary's task is to generate a valid tag on a message that hasn't been queried to the tag-generation oracle before, in polynomial time. If the adversary can do so ...
I have faced a problem to understand MD5 algorithm.My question is weather the original input message is converted to binary value in MD5 before using the input message as parameter in four Feistel permutations FF,GG,HH and KK? In order to understand my question here is an example. If the original input message is 'amra...
I am trying to implement TLS on top of the winsock api's from windows. I am using port 443 and have created a socket. I have sent this message in decimal. 22 3 1 0 112 1 0 0 108 3 1 48 227 142 116 0 1 4 9 1 25 4 17 0 17 4 25 16 9 4 1 0 1 4 9 16 25 4 17 0 17 14 25 16 0 0 68 192 10 192 20 0 13...
I am looking for block cipher modes of operation that are secure even when the number of blocks encrypted exceeds the birthday bound.
Has any protocol ever been proven secure in the random oracle model and then broken in practice, despite the use of a good hash function in the actual implementation?
If I encrypt my SDCard on my android phone using the built-in encryption software, and my phone dies for whatever reason, would I be able to easily by just using the pin/password to access that data later on my desktops [OS X, Windows and Linux]?
Are there any known MD5 hashes that can´t occure, no matter what (finite) input is taken? Thanks
Given a parity check matrix $A$ we define the $q$-ary lattice $$\Lambda(A) = \{x \in \mathbb Z^m\;:\;Ax\equiv0\pmod q\}$$ How to find the basis of the lattice and how to find its hermite normal form?
I want to extensively test my implementation of point addition and doubling. I have only one test vector with me. I need more values to test. In the web, I could find test vectors only for key pair generation and signature verification. So if anybody can refer me a link containing test vectors, it will be of great hel...
For example say we have two numbers a and b. Now is there any partial homomorphic encryption scheme that allows to compute (a-b)^2 over the ciphertexts of a and b without round trips.
I was reading about Ruby ciphers and found this: Although the key is generally a random value, too, it is a bad choice as an IV. There are elaborate ways how an attacker can take advantage of such an IV. As a general rule of thumb, exposing the key directly or indirectly should be avoided at all cost and excepti...
I am taking a class on Cryptology, and I'm having a hard time understanding the potential pitfalls of Diffie-Hellman. Specifically, the professor gave the following problem: Alice and Bob want to use Diffie-Hellman for key agreement and choose p = 982734982635928741927391824619283719654192837198273923771, however,...
In the media, I sometimes read about "backdoors" in encryption algorithms. I'd like to understand what such a backdoor actually consists of. Is it: a) a hidden weakness in the math formulas that can cause security to be broken by brute force in a reasonable amount of time rather than the universe's expected life span? ...
I was reading Apple's public letter here regarding the "backdoor" that they have been asked to create. I'm very unclear exactly what the issue is. There was no backdoor in the encryption algorithm that was actually used on the phone and it's doesn't seem as if they are being asked to create one (and sneak it onto pho...
I have these 3 Schemes: 1) J. Bethencourt, A. Sahai, and B. Waters, "Ciphertext-policy attribute-based encryption" 2) F. Guo, Y. Mu, W. Susilo, D. Wong, and V. Varadharajan, "Cp-abe with constant-size keys for lightweight devices" 3) L. Ibraimi, M. Petkovic, S. Nikova, P. Hartel, and W. Jonker, "Ciphertext-policy attri...
I would like to make sure I understood HMAC. Wikipedia declares it like: $$\operatorname{HMAC}(K,m)=H((K\oplus\text{opad})||H((K\oplus\text{ipad})||m))$$ If I want to use HMAC-SHA1, am I correct to say that: Let's say I take key length of 16 bytes. Does it mean that according to Wikipedia I must pad the key with zeros...
Using the keystream from the block cipher for both parts of the GMAC key (initialization and encrypting the auth tag) seems to produce a better mode of operation than GCM, as successful forgeries and nonce reuse only compromise the particular (key, nonce) pair, rather than compromising integrity for every message encry...
Rijndael could support block sizes up to 256 bits; this seems to be useful in AEAD. Wht did NIST restrict AES to a 128-bit block size?
I have an app that I store sensitive user data which requires user to set a password to login the app and I use this password as key to encrypt the data. Now, I want to add an option to login the app with PIN. My problem is if user adds a PIN obviously I can't use it to decrypt the data. The only solution comes to my m...
I am reading this article (pdf) on the Diffie–Hellman key exchange. It states the following: At this point, the Diffie-Hellman operation could be considered complete. The shared secret is, after all, a cryptographic key that could encrypt traffic. But completion at this point is very rare, because the shared secret is...
I was checking for authoritative sources to back up my recommendation of a minimum RSA key length of 1024 and was shocked to find that NIST 800-56Br1 and FIPS 186-4 both recommend at least 2048 bits with 3072 bits for TOP SECRET data. I found that other sources have similarly high recommendations based on expected lif...
If we have a encrypting function f(x, y) (x for input, y for key) and let's say we composite this function n times inside itself with the same y (like f(f(f(x, y), y), y)) and set the output to be z. Does there exist another function g(v) so that g(z)=x? Can this be proven for any kind of encryption function f(x, y) st...
I've implemented AES in my library with several variations: a straight C version, a version using x86 SSSE3, and a version using x86 AES-NI. The SSSE3 and AES-NI implementations are constant-time, whereas the C implementation uses lookup tables. My SSSE3 implementation is a bit (~20%) slower than my C implementation. ...
Can you explain the 'theta' step of the compression box: D[X] = C[X-1] ^ ROT(C[X+1, 1]) In this step all the indices should be taken modulo 5. Do we have have to rotate it after taking mod 5? And is C[X-1] left rotate or just putting the values of x as 0,1,2,3,4 and then taking mod 5? And ROTC[X+1,1] is right circula...
In lattice-based cryptography, given the basis of the lattice we compute the orthogonal vectors using Gram-Schmidt Orthogonalization process. What is the use of orthogonal vectors in lattices?
In rho step of SHA3, I have done right circular rotation whether its correct ?? I am doing in Verilog so I am using concatenation operator for rotation. For x=0 and y=1 that is A[0][1] rotation will be of 36 bits (See page 22 of the reference) RotA[0][1] = A[0][1]{[35:28],[63:36],[27:0]}; Is this rotation correct??
I have such situation. I have a device like dongle. But it has certain limitations. For example, it can only have implemented encryption and decryption functionality. The availability of ciphers which it can use it can use is also limited. Current option is 3DES. Now, I need to create a message authentication scheme (w...
I'm already doing classic DH with pre-shared key in my setup, and it prevents people knowing the same password from eavesdropping on others' traffic. But it doesn't cover situations where a third party authenticates to the server, then masquerades as the server to an incoming client, performing an authentication and th...
The current debate of the FBI trying to get Apple to assist in decrypting an iPhone made me wonder: Normally, upon turning on an iPhone, everything is decrypted using a 4-digit pin (or actually, a key that is derived from the PIN with a strong KDF, but that's not the point here). The key element of Apple's protection i...
PKCS5/7 pads the remaining data elements with a binary representation of how many space requires padding. This is useful and compact but what should I do in the following sample scenario below ? Example: Use case scenario is to use AES or any fixed length 128 bit block cipher to encrypt user supplied data where the use...