Click here to Skip to main content
15,900,482 members
Home / Discussions / C#
   

C#

 
GeneralRe: Parsing JSon Success Pin
pkfox15-Nov-18 23:19
professionalpkfox15-Nov-18 23:19 
GeneralRe: Parsing JSon Success Pin
OriginalGriff15-Nov-18 23:37
mveOriginalGriff15-Nov-18 23:37 
GeneralRe: Parsing JSon Success Pin
pkfox15-Nov-18 23:39
professionalpkfox15-Nov-18 23:39 
GeneralRe: Parsing JSon Success Pin
pkfox16-Nov-18 2:57
professionalpkfox16-Nov-18 2:57 
QuestionGuys need your help am trying to insert data in MS Access database but its giving me a "Syntax Error" and i cnt find the problem....please analyse it and help Pin
Member 1405572615-Nov-18 2:09
Member 1405572615-Nov-18 2:09 
AnswerRe: Guys need your help am trying to insert data in MS Access database but its giving me a "Syntax Error" and i cnt find the problem....please analyse it and help Pin
OriginalGriff15-Nov-18 2:17
mveOriginalGriff15-Nov-18 2:17 
AnswerRe: Guys need your help am trying to insert data in MS Access database but its giving me a "Syntax Error" and i cnt find the problem....please analyse it and help Pin
Member 1332584615-Nov-18 21:00
Member 1332584615-Nov-18 21:00 
QuestionTo MD5 or not? (or SHA256 instead, I guess...) Pin
Super Lloyd14-Nov-18 15:34
Super Lloyd14-Nov-18 15:34 
In my application I manage multiple resources, i.e. potentially large binary files (i.e. images).
I want each image to be added only once. But I try to make this comparison quick instead of comparing each bytes of the new image/resource to each bytes of existing resources.

The trick I came up with is to compute a unique ID for each resource using MD5. Which nicely return a unique 16 bytes array, which nicely convert into a Guid, which I can then nicely store into a Dictionary<Guid, Resource>

Now it was brought to my attention that MDA5 is "insecure" and I should use SHA256 instead.
The problem I have with that (hence my question) is that SHA256 is more annoying to use, my data should be a multiple of 16 bytes long. Also it return a 32 byte array which cannot easily be turned into Guid.

So here is my conundrum. All I want is a unique ID for resource. This is not a security risk, just a quicker way to avoid resource duplication inside the document.
Do I really need to use SHA256? i.e. is it likely the "insecure nature" of MD5 will accidentally collide hash keys of random resources / images?
A new .NET Serializer
All in one Menu-Ribbon Bar
Taking over the world since 1371!

AnswerRe: To MD5 or not? (or SHA256 instead, I guess...) PinPopular
Dave Kreskowiak14-Nov-18 16:37
mveDave Kreskowiak14-Nov-18 16:37 
GeneralRe: To MD5 or not? (or SHA256 instead, I guess...) Pin
Super Lloyd14-Nov-18 17:41
Super Lloyd14-Nov-18 17:41 
AnswerRe: To MD5 or not? (or SHA256 instead, I guess...) PinPopular
OriginalGriff14-Nov-18 19:52
mveOriginalGriff14-Nov-18 19:52 
GeneralRe: To MD5 or not? (or SHA256 instead, I guess...) Pin
Super Lloyd14-Nov-18 20:05
Super Lloyd14-Nov-18 20:05 
GeneralRe: To MD5 or not? (or SHA256 instead, I guess...) Pin
OriginalGriff14-Nov-18 20:09
mveOriginalGriff14-Nov-18 20:09 
Questionc# Win Forms, Event Handlers, Store a global setting and retrieve it in an event handler Pin
jkirkerx14-Nov-18 13:28
professionaljkirkerx14-Nov-18 13:28 
AnswerRe: c# Win Forms, Event Handlers, Store a global setting and retrieve it in an event handler Pin
OriginalGriff14-Nov-18 19:58
mveOriginalGriff14-Nov-18 19:58 
GeneralRe: c# Win Forms, Event Handlers, Store a global setting and retrieve it in an event handler Pin
jkirkerx15-Nov-18 7:54
professionaljkirkerx15-Nov-18 7:54 
AnswerRe: c# Win Forms, Event Handlers, Store a global setting and retrieve it in an event handler Pin
Nathan Minier15-Nov-18 1:17
professionalNathan Minier15-Nov-18 1:17 
GeneralRe: c# Win Forms, Event Handlers, Store a global setting and retrieve it in an event handler Pin
jkirkerx15-Nov-18 7:58
professionaljkirkerx15-Nov-18 7:58 
AnswerRe: c# Win Forms, Event Handlers, Store a global setting and retrieve it in an event handler Pin
BillWoodruff15-Nov-18 13:36
professionalBillWoodruff15-Nov-18 13:36 
GeneralRe: c# Win Forms, Event Handlers, Store a global setting and retrieve it in an event handler Pin
jkirkerx16-Nov-18 9:40
professionaljkirkerx16-Nov-18 9:40 
AnswerRe: c# Win Forms, Event Handlers, Store a global setting and retrieve it in an event handler Pin
Mycroft Holmes15-Nov-18 13:59
professionalMycroft Holmes15-Nov-18 13:59 
GeneralRe: c# Win Forms, Event Handlers, Store a global setting and retrieve it in an event handler Pin
jkirkerx16-Nov-18 9:44
professionaljkirkerx16-Nov-18 9:44 
QuestionCorrelation Between two different Charts in C# Pin
Member 1332584614-Nov-18 12:08
Member 1332584614-Nov-18 12:08 
QuestionDetect Network / VPN Connection Pin
Kevin Marois14-Nov-18 7:25
professionalKevin Marois14-Nov-18 7:25 
AnswerRe: Detect Network / VPN Connection Pin
Eddy Vluggen15-Nov-18 1:21
professionalEddy Vluggen15-Nov-18 1:21 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.