Questions tagged [sha256]

Sha256 is a hashing algorithm.

0
votes
0answers
15 views

Validate SHA-256 thumbprint before send flle with scp

A file is send from ServerA to ServerB using self written automation tool via scp bash command. There is SHA-256 thumbprint required for ServerB host validation. What is the correct approach here to ...
0
votes
0answers
52 views

How to verify a binary correctly even if my github account is hacked by someone

I have a binary file and saved it on github release page. https://github.com/zono/bolt8/releases To allow users to verify it, I saved sha256sum and signature(.asc). However I have a concern that if ...
0
votes
0answers
151 views

Secure Http Connection With Authentication Header

I am trying to create an authentication header algorithm that can be used for authentication on HTTP server. Not sure it is good but it seems OK to me. I also used similar approaches for previous WS ...
3
votes
1answer
174 views

Crack 8-char password with known number of set bits

At University, I got some CTFs to do for my security lectures. Basically, I need to crack an 8-character password (96 possible characters). I know that 42 of the 64 bits are set to 1 and I know the ...
1
vote
3answers
102 views

Which function to hash 128 bit API key with?

I'm generating 128 bit API keys. AFAIK 128 is totally secure for generated key. In the DB I want to store hashes, not the plain text (to be protected against DB leak), but what hashing algorithm ...
0
votes
1answer
122 views

I need to compute a string whose SHA256 hash matches a given prefix. How should I approach it? [duplicate]

Is there any (more efficient) way for computing any string with a given prefix in it's SHA 256 hash? And how probable am I to stumble on such a string if I brute force?
0
votes
0answers
57 views

Does the password goes weaker as they get longer since hash has a fixed length? [duplicate]

For example, sha256 has a fixed hash length of 64 characters. So I'm wondering will a password goes weaker as they get longer and longer? Since no matter how long your password goes, the sum will be ...
4
votes
6answers
775 views

How likely is a collision using MD5 compared to SHA256 (for checking file integrity)?

Many sites these days offer MD5 and SHA256 hashes to check the integrity of downloaded files or archives. I wonder how much safer is the use of the SHA256 hashes for integrity checks? Note: Consider ...
0
votes
1answer
53 views

How are these transaction fingerprints colored?

For those unfamiliar, blockchains have two main types of data structures propagated in their networks: blocks and transactions. Each block and transaction has a hash, just like key fingerprints. The ...
0
votes
3answers
160 views

Is it easier to calculate a partial SHA256 collision than a full one?

Question: Disregarding brute-force, is it any easier to calculate a partial hash collision, in which only a certain number of bits match? Reasoning: On many websites you find hashes for file ...
1
vote
1answer
185 views

Error detection capability of SHA-256

If we use SHA-256 checksum to detect corruptions to a file, what is its capability in terms of missed errors? For example, reading the page about error correction and detection here, under the ...
0
votes
0answers
277 views

How to mask attack a sha256 hash with following information using hashcat?

I am hashcat newbie and I want to crack a hash :) The answer is 1-15 (unknown) characters and it may contain 'a-z' 'A-Z' '0-9' and '_' . (A Twitter username) How may I mask attack a hash with above ...
5
votes
2answers
3k views

Why is SHA-256 not good for passwords? [duplicate]

I've just started learning about all of this and I can't really find an answer for that anywhere, namely why is SHA-256 not used for passwords? I found that the reason is that because normal SHA-256 ...
1
vote
2answers
65 views

Confusion about the software and also the digital signature getting modified

I'm not sure what is very secure about digitally signing a software or firmware to distribute. I understand the benefit in that it can let the receiver know if the data accidentally got corrupted ...
2
votes
1answer
220 views

Is it possible to tell if a file's message digest is MD5 or SHA-256?

There's some old data encrypted with OpenSSL 1.0.2, but now OpenSSL is at 1.1.0. I understand from OpenSSL FAQ USER3 that an old file can be decrypted with 1.1.0 by using -md md5. But let's say you ...
2
votes
1answer
4k views

How to decrypt a gpg file?

I have a gpg file and a sha256 file. When I try to decrypt the gpg file using the gpg - d file.gpg command, it says that there is no secret key. I am absolutely new to this so I would appreciate any ...
4
votes
1answer
404 views

when should i use HMAC-based JWT?

I read a number of blog posts and found that it is tough to keep the secret-key a secret and if using a symmetric algorithm for JWT creation, the generator has the power to create as well as validate ...
-2
votes
1answer
61 views

SHA256 Encrypting with Value [closed]

Is it possible to encrypt a value (such as "hello world") with itself ("hello world") using an encrypting technique such as SHA256? Is that safe to do or would it be easily compromised?
0
votes
2answers
139 views

Sha256 hash + secret GUID + RNGCrypto random number to hash passwords

I'm maintaining a website which uses Sha256 hashing of passwords. The passwords are hashed with a GUID key, and a RNGCrypto generated random salt. I'm just trying to understand the security risks ...
0
votes
2answers
495 views

Generating salt for hash that occurs on server and client

Let's say I have an API call which is supposed to check if email address exists in the DB, without transmitting the actual email address. For that purpose, I've decided to store SHA256 hash of the ...
3
votes
2answers
414 views

Can AES and SHA-256 outputs with the same inputs be used to break each other?

An abstract representation of my question looks like this: byte[] encrypted = AES.Encrypt(bytesToEncrypt, password); byte[] hash = SHA256.Hash(password); If an attacker obtains the values of both ...
54
votes
5answers
12k views

Is it secure to use MD5 to verify the integrity of small files (less than 15kb)?

I know that collision for MD5 has been documented since the 90s and that digital certificates based off of MD5 has been demonstrated to be completely compromised back in 2010 but how effective is MD5 ...
1
vote
3answers
187 views

Should Hashes of Sensitive Data be Encrypted

I'm planning on storing chunks of encrypted data inside a file, along with each chunk would be the hash(sha256) of the unencrypted chunk stored in the file as well. Is storing the hash secure?
6
votes
2answers
426 views

Is it safe to use a Windows executable with expired SHA256 certificate but valid SHA1 certificate?

Microsoft's Media Creation Tool to create Windows 10 installation media has a SHA1 digital signature and a SHA256 digital signature (shown via file properties). However, the certificate for SHA256 ...
1
vote
2answers
2k views

Decoding a HMAC SHA256 when the key is the same as the original string

Theoretically, python function for encrypting a HMAC SHA256 looks like this: hmac_sha256(key, text) The word "hello" was encrypted using the function like so: hmac_sha256("hello", "hello") How ...
0
votes
3answers
111 views

Producing secure hashes to detect data manipulation

I have an Android app that internally relies on a SQLite database that stores encrypted user data. The data is encrypted using AES-256, with a key generated by the PBKDF2-HMACSHA256 algorithm. The ...
2
votes
0answers
90 views

How bad is it to generate passwords via sha256, rather than storing them with a pw manager? [duplicate]

I've been pondering how to deal with passwords lately. I'd been using a password manager for awhile, but this means I can't access anything I use it for from a machine where it isn't installed (or ...
7
votes
3answers
502 views

Hashing a large file on an embedded system

I'm trying to come up with a way to verify the authenticity of a file that I'm downloading from a server to an embedded system. I'm thinking of using a hash (SHA256 preferably). My main concern is ...
2
votes
4answers
2k views

Is using 100,000 iterations of sha256 good enough for password storage? [duplicate]

I am creating a web app, and I was wondering if it would be secure to use 100,000 iterations of sha256 for storing passwords? I know that there are algorithms such as scrypt and bcrypt, however, I was ...
3
votes
1answer
170 views

How is the bitcoin block header data padded for SHA256 hashing?

I see that a block contains 80 bytes. SHA256 expects integral multiples of 64 bytes as input. How are the remaining 48 bytes calculated?
0
votes
1answer
2k views

HMAC-SHA256 for JWT Token Signature

I am currently working at a company in which we have the need to design a token based authentication system. We will be the owners and controlers of two servers, one being the authentication server ...
1
vote
1answer
324 views

Interoperability of openssl smime, rsautl & dgst

How do $ openssl smime -sign -in test -text -out mail.msg -signer mycert.pem -inkey key.key and $ openssl rsautl -sign -inkey key.key -out test.sgn -in test and $ openssl dgst -sha256 -sign key....
2
votes
1answer
101 views

E-Mail signature examination

If I download a signed e-mail from thunderbird, it looks like this: Content-Type: multipart/signed; protocol="application/pkcs7-signature"; micalg=sha-256; boundary="------------...
2
votes
2answers
77 views

Analysis of gpg2 packets

I want to mentally visualize or just understand a gpg-signature. When running $ gpg2 --list-packets --verbose < test.sig the output is # off=0 ctb=89 tag=2 hlen=3 plen=540 :signature packet: ...
3
votes
2answers
384 views

Why are passwords sent unhashed by most modern websites? [duplicate]

I've been investigating various protocols used to send usernames and passwords to web servers in order to authenticate, and while obviously all of them these days use SSL/TLS, I was a bit surprised to ...
3
votes
1answer
284 views

Is appending a salt before hash generation enough

I have what I think is a securely generated salt/hashing mechanism for HMAC authentication based on SHA256 in place. However, I'm using the salt in, from what I can see, a fairly standard way of just ...
0
votes
1answer
116 views

Given a hash value, is it possible to determine the length of the initial string that was digested? (SHA256)

Also, given two hash values, is it possible to determine if either one of them was a result of digesting a larger string? As far as I understand SHA256, nothing but guessing the string itself helps. ...
1
vote
0answers
437 views

ways to check a certificate fingerprint against known logs

Suppose I have a certificate sha-256 fingerprint, which I can obtain say visiting the relevant domain in firefox or from a shell script using openssl, and i want to verify this fingerprint. one option ...
1
vote
1answer
228 views

compare sha-256 fingerpirnt of certificate with google transparency report

Say that I want to check an https certificate. Suppose I know its SHA-256 fingerprint, how do I compare it to this service search tool, which apparently only gives me the serial number? edit1: can ...
0
votes
2answers
308 views

Inconsistency Among MD5, SHA1, and SHA256 Hashing Protocols

There appears to be an inconsistency (or unpublished protocol) in many online hash generators when formulating a hash from an uploaded text file, versus strictly hashing the contents of a file. This ...
0
votes
1answer
96 views

Can a secret, S, be efficiently recovered from a list of usernames and SHA256(S + username)s?

Given a set of usernames and their corresponding proofs of knowledge of a shared secret: SHA256($SECRET + username), can an attacker recover $SECRET more efficiently than by brute force? (This is ...
1
vote
1answer
654 views

SHA256 for IV for AES-256 CBC?

When making an IV for AES-256 CBC mode the IV should be random and shouldn't be able to be guessed. If I were to use the rand() function in C, seeded with time(NULL) to generate sim random numbers ...
5
votes
2answers
9k views

Is SHA-256 + Salt still safe for password storage? [duplicate]

I am developing a website which requires users to register to it in order to use it's functions and I was wondering if SHA-256 + salt (random salt provided by RNGCryptoServiceProvider in C#) is ...
-1
votes
2answers
457 views

How can I make a program to verify file integrity? [closed]

How to make a program that calculates a checksum of a file? What is the exact process of calculating a checksum?
1
vote
0answers
2k views

How to reasonably hash a composite key into a UUID?

The Problem In our system users are identified by a composite key. We'd like to devise a scheme to deterministically convert this composite key into a UUID. Solutions? The obvious first suggestion ...
2
votes
2answers
7k views

How does this site decrypt SHA256 hashes? [duplicate]

I thought sha256 is impossible to crack (so far). But I saw a website, that could decrypt my hash. So is this because they store known hastes in a database or do they really decrypt hashes? Here's an ...
1
vote
2answers
202 views

How can we retire SHA1 in prefernce to SHA256 or SHA-3?

According to http://www.pcworld.com/article/3174676/security/sha-1-collision-can-break-svn-code-repositories.html and https://www.theregister.co.uk/2017/02/23/google_first_sha1_collision/ you could ...
1
vote
2answers
2k views

Brute force HMAC SHA256 (HS256) equals to break JSON web token signature?

The format of JSON Web Token is: encoded (header). encoded(payload). signature with a secret (for example, use sha256 to sign). In case of hmac sha256 (HS256)-selected JWT, if the secret is not long ...
10
votes
1answer
3k views

What kind of hashing to use for storing REST API tokens in the database?

We have a REST API that communicates with a mobile front-end. After submitting a one time password, the backend will issue a token (random UUID v4 string) for the mobile app to use as authentication ...
0
votes
2answers
3k views

Recover key in HMAC-SHA256 message authentication [closed]

I am working on a demonstration of cookie security, where some important data is passed to the client along with a HMAC-SHA256 digest to prevent modification of the data. I would like to be able to ...