HIBPwned, an R package for HaveIBeenPwned.com

March 21, 2016
By

[This article was first published on R – It's a Locke, and kindly contributed to R-bloggers]. (You can report issue about the content on this page here)
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.

The answer in life to the inevitable question of “How can I do that in R?” should be “There’s a package for that”. So when I wanted to query HaveIBeenPwned.com (HIBP) to check whether a bunch of emails had been involved in data breaches and there wasn’t an R package for HIBP, it meant that the responsibility for making one landed on my shoulders. Now, you can see if your accounts are at risk with the R package for HaveIBeenPwned.com, HIBPwned.

Have I Been Pwned | HaveIBeenPwned.com
Have I Been Pwned | HaveIBeenPwned.com

Current status

The package is currently available on github @ stephlocke/HIBPwned, but I intend to submit to CRAN after getting some feedback from y’all.

if(!require("devtools")) install.packages("devtools")
# Get or upgrade from github
devtools::install_github("stephlocke/HIBPwned")
library("HIBPwned")

Basic usage

The very first thing you should do after installing is checking to see if your personal email address has been breached.

HIBPwned::account_breaches("[email protected]")

After that, check your significant other, your cat, and your family who you probably provide IT support for.

HIBPwned::account_breaches(c("[email protected]", "[email protected]"))

Give it a whirl!

Package development notes

  • HIBP is a fantastically written API and isn’t complicated so I’ve almost got the R package to be feature complete with respect to the API.
  • The package enjoys 100% test coverage as the simplicity of the API has enabled thorough testing
    Coverage Status
  • The package uses the latest iteration of the R travis-ci capabilities

The post HIBPwned, an R package for HaveIBeenPwned.com appeared first on It's a Locke.

To leave a comment for the author, please follow the link and comment on their blog: R – It's a Locke.

R-bloggers.com offers daily e-mail updates about R news and tutorials about learning R and many other topics. Click here if you're looking to post or find an R/data-science job.
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.



If you got this far, why not subscribe for updates from the site? Choose your flavor: e-mail, twitter, RSS, or facebook...

Comments are closed.

Search R-bloggers

Sponsors

Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)