Questions tagged [sha2]

sha-2 refers to the family of secure hash functions consisting of SHA-224, SHA-256, SHA-384, and SHA-512. These are defined by the US NIST in FIPS 180-4.

sha-2 refers to the family of secure hash functions consisting of SHA-224, SHA-256, SHA-384, and SHA-512. These are defined by the US NIST in FIPS 180-4.

135 questions
1
vote
1 answer

How to sign digitally with SHA-2 in PowerShell (NOT OpenSSL)

How can I sign digitally a string with SHA-2 by PowerShell script, not using OpenSSL? I know how to do it with OpenSSL, but I'm wondering if there is a way to do it with .Net classes. Thank you.
Allen L
  • 127
  • 1
  • 11
1
vote
3 answers

SHA2 server SFTP fingerprints using Renci.SshNet

I'm using Renci.SSHNet to establish a connection to SFTP servers. I've done so without any problems but I've recently ran into a server to which I can´t establish a connection through my code. I keep getting the following error: No suitable…
user6062387
  • 13
  • 1
  • 3
1
vote
1 answer

Does double hashing with the same algorithm increase hash collision?

If I use MD5, as an example, twice with some data, will it increase the probability of collision? And what about SHA? I am asking this because I thought of hashing a password in the client and then again in the server.
Jader Dias
  • 88,211
  • 155
  • 421
  • 625
1
vote
0 answers

Twitter OAuth integration without HTTPS on my side

Do I need HTTPS on my server with some SHA-2 certificate for Twitter OAuth integration? Or may I simply send HTTPS requests to the Twitter API after receiving OAuth access token?
Dmytro Zarezenko
  • 10,526
  • 11
  • 62
  • 104
1
vote
1 answer

Moving to SHA-2

I have a website with about 60,000 paying customers 3000 of them use windows XP + IE 8. I want to have a certificate that would serve all of my clients (or multi-certificate solution). the issue is that SHA-1 is deprecated so I want to move to…
1
vote
5 answers

Is disposing this object, enough? or do i need to do more?

I have this code :- using (System.Security.Cryptography.SHA256 sha2 = new System.Security.Cryptography.SHA256Managed()) { .. } Do I need to put this line of code, just BEFORE I leave that dispose scope .. or does the dispose 'call' that…
Pure.Krome
  • 84,693
  • 113
  • 396
  • 647
1
vote
1 answer

Is it possible to generate a subca or sign any csr with SHA-2 when the issuer is using SHA-1

I have a rootca using SHA-1 algorithm. Is it possible to generate a subca or sign any csr with SHA-2. Migrating from SHA-1 to SHA-2 is not an option. I want to have cerificate with SHA-2 with its issuer using SHA-1.Is there any link to have more…
Saikat
  • 403
  • 1
  • 7
  • 19
1
vote
1 answer

Which SHA-2 function will Facebook use?

I read that Facebook on the 1st Oct 2015 will move from SHA-1 to SHA-2 and we have to update our applications: https://developers.facebook.com/blog/post/2015/06/02/SHA-2-Updates-Needed/ Do you know which function of SHA-2 will it use? I read there…
1
vote
1 answer

Does halving every SHA224 2 bytes to 1 byte to halve the hash length introduce a higher collision risk?

Let's say I have strings that need not be reversible and let's say I use SHA224 to hash it. The hash of hello world is 2f05477fc24bb4faefd86517156dafdecec45b8ad3cf2522a563582b and its length is 56 bytes. What if I convert every two chars to its…
Alper Turan
  • 1,220
  • 11
  • 24
1
vote
1 answer

Wrong hash output in C implementation of sha2 256

I've implemented sha2 256 based on the rfc spec found at: https://www.rfc-editor.org/rfc/rfc4634. My implementation: #include #include #include #include #include uint32_t K[] =…
Burmudar
  • 263
  • 5
  • 14
1
vote
2 answers

Need to create a SHA2 hash in c#

I write a small program using the Vircurex API for trading e-currencies. Their documentation is using Ruby code examples and I am unsure of what the equivalent is in C#. For anyone interested, their documentation is listed…
Kasper Hansen
  • 6,307
  • 21
  • 70
  • 106
1
vote
2 answers

casting long to unsigned char in SHA-2 algorithm

in InChi library (available here: http://www.iupac.org/home/publications/e-resources/inchi.html) there is a custom implementation of SHA-2 algorithm which (implementation, not an algorithm) I'm trying to understand. In particular one short fragment…
mnowotka
  • 16,430
  • 18
  • 88
  • 134
1
vote
2 answers

MySQL on Windows: Using SHA-2

I need to store sensitive data (usernames and passwords) and wanted to do things the right way (storing SHA-256 hashes of (password).(large random number) instead of cleartext passwords. This needs to be done using MySQL and, as far as i know, only…
João Pereira
  • 3,545
  • 7
  • 44
  • 53
1
vote
2 answers

Matching Java SHA2 Output vs MySQL SHA2 Output

When I reproduce a SHA2 hash via the following code: MessageDigest digest = MessageDigest.getInstance("SHA-256"); digest.digest("A".getBytes("UTF-8")); it gives me a byte array, which is:…
markAnthopins
  • 237
  • 2
  • 12
0
votes
0 answers

Does an HMAC in an automated system provide any practical protection that a normal hash can't assuming proper parsing?

From my research on using HMAC, it protects against length extension attacks on Merkle-Damgård hash algorithms. Is an HMAC only useful in the circumstance that the message syntax allows for lengthening and the key precedes the message when…
1 2 3
8 9