The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 2,232 other followers

Archive for the ‘Python’ Category

Making it dead simple to implement @haveibeenpwnd in your applications, including strength warning if found in @troyhunt’s password collection.

Posted by jpluimers on 2020/12/02

I wasn’t aware that Troy Hunt created an API [WayBack] for [WayBack] Have I Been Pwned: Check if your email has been compromised in a data breach.

He did, as I noticed through [WayBack] Michelangelo van Dam on Twitter: “Making it dead simple to implement @haveibeenpwnd in my applications, including strength warning if found in @troyhunt’s password collection. Check out to try it out yourself. #ImproveSecurity #haveibeenpwnd”.

There are in fact plenty of other packages, web-sites and apps using the API as seen on [WayBack] Have I Been Pwned: API consumers.

Many people ask “if it is safe” (often assuming passwords are sent in clear, or hashes are sent in full; my fear is that those people implement security somewhere).

It is safe:

PHP source is at [WayBack] GitHub – DragonBe/hibp: A composer package to verify if a password was previously used in a breach using Have I Been Pwned API.

There is also a [WayBack] composer package at [WayBack] dragonbe/hibp – Packagist.

A really cool thing on it is this:

This project was also the subject of my talk [WayBack] Mutation Testing with Infection where the code base was not only covered by unit tests, but also was subjected to Mutation Testing using [WayBack] Infection to ensure no coding mistakes could slip into the codebase.

Apart from the tests, the most important source is at [WayBack] hibp/Hibp.php at master · DragonBe/hibp · GitHub

Related:

–jeroen

Posted in Development, Mobile Development, PHP, Python, Scripting, Software Development, Web Development | Leave a Comment »

Brew reminder to self

Posted by jpluimers on 2020/08/05

From the update process:

==> Caveats
==> hub
Bash completion has been installed to:
  /usr/local/etc/bash_completion.d

zsh completions have been installed to:
  /usr/local/share/zsh/site-functions
==> python
Python has been installed as
  /usr/local/bin/python3

Unversioned symlinks `python`, `python-config`, `pip` etc. pointing to
`python3`, `python3-config`, `pip3` etc., respectively, have been installed into
  /usr/local/opt/python/libexec/bin

If you need Homebrew's Python 2.7 run
  brew install python@2

You can install Python packages with
  pip3 install 
They will install into the site-package directory
  /usr/local/lib/python3.7/site-packages

See: https://docs.brew.sh/Homebrew-and-Python
==> youtube-dl
Bash completion has been installed to:
  /usr/local/etc/bash_completion.d

zsh completions have been installed to:
  /usr/local/share/zsh/site-functions
==> mpv
zsh completions have been installed to:
  /usr/local/share/zsh/site-functions
==> node
Bash completion has been installed to:
  /usr/local/etc/bash_completion.d

–jeroen

Posted in Apple, Development, Home brew / homebrew, Power User, Python, Scripting, Software Development | Leave a Comment »

pip install –user and your path

Posted by jpluimers on 2020/06/09

I’ve added this to my ~/.bashrc to stuff installed by pip install --user is accessible from interactive shells:

# set PATH so it includes user's private python "pip --user" bin if it exists
if [ -d "$HOME/.local/bin" ] ; then
    PATH="$PATH:$HOME/.local/bin"
fi

The addition is at the end of the path. It is a choice: it means machine installs take prevalence over user installs. That’s usually what I want. For more considerations (including non-interactive shells), see [WayBack] bash – How to correctly add a path to PATH? – Unix & Linux Stack Exchange.

The --user installs do not affect the full system, nor other users.

Further reading:

–jeroen

Posted in Development, Python, Scripting, Software Development | Leave a Comment »

MultiBootUSB

Posted by jpluimers on 2020/05/07

Cool tool:

MultiBootUSB is a cross platform software written in python which allows you to install multiple live linux on a USB disk non destructively and option to uninstall distros. Try out the world’s first true cross platform multi boot live usb creator for free. Download Now!

Information and downloads on [WayBackMultiBootUSB.

There are actually a few repositories within [WayBack] mbusb (multibootusb) · GitHub of which one has a ruby implementation as well.

A more elaborate article is on [WayBack] How to Install Multiple Linux Distributions on One USB, but the site should get you going just fine.

Via: [WayBack] Multiple Linux distributions on one UBS stick. I just tried it with: * CloneZilla * Lubuntu * LiteLinux The tool they describe – MultiBootUSB – comes w… – Thomas Mueller (dummzeuch) – Google+

–jeroen

Posted in *nix, *nix-tools, Development, Hardware, Linux, Power User, Python, Software Development, USB | Leave a Comment »

GitHub – ofek/hatch: A modern project, package, and virtual env manager for Python

Posted by jpluimers on 2020/05/04

Cool: [WayBack] GitHub – ofek/hatch: A modern project, package, and virtual env manager for Python

Via: [WayBack] Hatch: A modern project, package, and virtual env manager for Python – ThisIsWhyICode – Google+

–jeroen

Posted in Development, Python, Scripting, Software Development | Leave a Comment »

 
%d bloggers like this: