Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: crystal-lang/crystal
base: 2eca01b92d84
Choose a base ref
...
head repository: crystal-lang/crystal
compare: 78b43559165f
Choose a head ref
  • 3 commits
  • 19 files changed
  • 2 contributors

Commits on Sep 25, 2017

  1. Merge SecureRandom into Random and Random::Secure

    SecureRandom has been dropped in favor to Random::Secure (renamed
    from Random::System) which is now the secure source for random
    numbers suitable for cryptography.
    
    Moves SecureRandom#random_bytes(Bytes) into Random::Secure, and
    implements a generic Random#random_bytes(Bytes) to fill a Bytes with
    random numbers from any PRNG.
    
    Moves SecureRandom methods such as #base64 and #uuid into Random, so
    any PRNG implementation may use these methods; they should only be
    used with a secure PRNG thought (except maybe in test suites). This
    change allows to swap PRNG at will. For example swap Random::Secure
    for Random::ISAAC (seeded from Random::Secure), or use a
    cryptographically secure but slow PRNG in production, and an
    insecure but fast and determinable PRNG in test suites, for example.
    ysbaddaden committed Sep 25, 2017
    Copy the full SHA
    27684db View commit details
    Browse the repository at this point in the history
  2. Copy the full SHA
    79d0358 View commit details
    Browse the repository at this point in the history

Commits on Sep 26, 2017

  1. Merge pull request #4894 from ysbaddaden/std-merge-secure-random-into…

    …-random
    
    Merge SecureRandom into Random and Random::Secure
    
    - Renames Random::System to Random::Secure.
    - Removes SecureRandom.
    - Moves #uuid, #hex and #base64 methods to Random.
    - Moves SecureRandom#random_bytes(slice) to Random::Secure.
    - Implements generic Random#random_bytes(slice).
    ysbaddaden committed Sep 26, 2017
    Copy the full SHA
    78b4355 View commit details
    Browse the repository at this point in the history