Suchergebnisse mit Tag „hash“

TOP

Hash function speed comparison

I need to hash strings to a shorter checksum on a "BigData" heavy-throughput project. The common choice would be SHA, probably SHA1 for speed reasons or CRC32 as the checksums will be used internally only and don't need to be cryptographic secure. A StackExchange answer suggested MurmurHash3, but how does it play with Perl?

Weiterlesen
TOP

Reference found where even-sized list expected

I started working myself though a long list of unfixed warnings today and encountered something I didn't see before: Reference found where even-sized list expected at project/Something.pm:573. The message seems to be clear, but do you find the problem at line 573?

Weiterlesen
TOP

The five faces of a Perl hash item

PHP calls it associative array, JavaScript calls it object and - in the eyes of other (older) languages like C, BASIC, Pascal or Perl - all of them are wrong. An array has some items which may be addressed using their position in the list, but only a Perl hash has named keys. A hash is basically an (unordered) list of items where each item has a key and a value - but that value may have one of many different states.

Weiterlesen
TOP

Hash to string race

How to convert a hash to a string? Perl is TIMTOWTDY but which way is the fastest? I need a checksum (hash, digest) for the hash, so the string must be the same for the same hash every time. Hash keys are not sorted, even a simple join('', keys(%hash)) may be different for each call (if the hash has at least two keys).
Weiterlesen
TOP

When slower is better: Secure your passwords

It happend to PerlMonks, Sony and many others: A plain text password table was stolen from the database. Read this carefully to not become the next one on that list.

Weiterlesen
TOP

Perl-Sünden

Den heutigen Tag habe ich gefühlt nur mit Bugfixes verbracht. Keine komplizierten, schwer zu findenden Bugs, sondern kleine fiese dumme Minikäfer die einfach nur nervig sind.

Weiterlesen