exploit the possibilities
Home Files News &[SERVICES_TAB]About Contact Add New

Strong Password Generator Biased Randomness

Strong Password Generator Biased Randomness
Posted Apr 13, 2018
Authored by Sean Buckley

Chrome's "Strong Password Generator" extension suffers from a weakness with password generation.

tags | advisory
SHA-256 | 4d5fb6b5e8fa4ac112b35defcafc80e9de797feca81f0813ed90688201e18da5

Strong Password Generator Biased Randomness

Change Mirror Download
Hi list!

I am posting my findings here in hopes some may find it interesting, and to
provide yet another example of why not to trust browser extensions blindly.
This is the top chrome web store search result for "password generator".
It has 35,000 users. This was hardly a difficult bug to find, taking
just a few minutes, but I was unable to find it online anywhere else.

https://chrome.google.com/webstore/detail/strong-password-generator/emehklffcaphknhhfhadkjhpfapcbpco

This password generator contains a logic flaw, which results in some
characters appearing more frequently than others in generated passwords.

On 2018-03-27, I reported this issue using the "support" section of
the extension's page on the chrome web store.
On 2018-04-10, I checked back again to discover that the support section for
this extension has been switched off. This extension was last updated over 5
years ago. I have concluded that the developer isn't interested in it anymore.

In fairness, despite this flaw, this password generator is
still probably better than no password generator at all.

------------------------------------------------------------------------------

This line of code is taken from the extension.
The array "keys" stores the characters that generated passwords can contain.
This is how a random character from the keys array is selected:
{
var keyPos = Math.round(Math.random() * (keys.length - 1));
}

Consider generating passwords with the custom character set "ABC".
Math.random()*(keys.length-1) produces a number between 0.0 to 2.0
It shouldn't take long to conclude that a random value between
0.0 and 2.0, when rounded, will produce 1 twice as often as either 0 or 2

Here are some passwords I generated using the character set "ABC":
BBBBBBCACCBCBCCABBCBBBCCCAABBAAABABCCBBCBACBACACBBABBBBBCBBBBCBA
BACBBABBCBBAAABCBABBBCBABCCCBCCBCBAABBBCBCACABABABBBCBBBCCBBABBC
BBBBBABCAAAAABBACCBAAABBACBCBCBBABBBBACBBCBAACBBBCAAACBBACAABAAB
ACBABABABCCBBBBBABBBBBACBCACCABBCBCBCCBCABBACACCBCBBBBCABBBABABC

A appears 64 times, B appears 127 times, and C appears 65 times


Login or Register to add favorites

File Archive:

April 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Apr 1st
    10 Files
  • 2
    Apr 2nd
    26 Files
  • 3
    Apr 3rd
    40 Files
  • 4
    Apr 4th
    6 Files
  • 5
    Apr 5th
    26 Files
  • 6
    Apr 6th
    0 Files
  • 7
    Apr 7th
    0 Files
  • 8
    Apr 8th
    22 Files
  • 9
    Apr 9th
    14 Files
  • 10
    Apr 10th
    10 Files
  • 11
    Apr 11th
    13 Files
  • 12
    Apr 12th
    14 Files
  • 13
    Apr 13th
    0 Files
  • 14
    Apr 14th
    0 Files
  • 15
    Apr 15th
    30 Files
  • 16
    Apr 16th
    10 Files
  • 17
    Apr 17th
    22 Files
  • 18
    Apr 18th
    45 Files
  • 19
    Apr 19th
    0 Files
  • 20
    Apr 20th
    0 Files
  • 21
    Apr 21st
    0 Files
  • 22
    Apr 22nd
    0 Files
  • 23
    Apr 23rd
    0 Files
  • 24
    Apr 24th
    0 Files
  • 25
    Apr 25th
    0 Files
  • 26
    Apr 26th
    0 Files
  • 27
    Apr 27th
    0 Files
  • 28
    Apr 28th
    0 Files
  • 29
    Apr 29th
    0 Files
  • 30
    Apr 30th
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2022 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close