All Projects → martinspielmann → haveibeenpwned4j

martinspielmann / haveibeenpwned4j

Licence: Apache-2.0 License
The ultimate Java library for Troy Hunt's ';-- Have I Been Pwned (v3).

Programming Languages

java
68154 projects - #9 most used programming language

Projects that are alternatives of or similar to haveibeenpwned4j

Lil Pwny
Fast, offline auditing of Active Directory passwords using Python.
Stars: ✭ 117 (+800%)
Mutual labels:  password-safety, haveibeenpwned
Password Leak
A library to check for compromised passwords
Stars: ✭ 92 (+607.69%)
Mutual labels:  password-safety, haveibeenpwned
H8mail
Email OSINT & Password breach hunting tool, locally or using premium services. Supports chasing down related email
Stars: ✭ 2,163 (+16538.46%)
Mutual labels:  hibp, haveibeenpwned
hibpwned
Python API wrapper for haveibeenpwned.com (API v3)
Stars: ✭ 21 (+61.54%)
Mutual labels:  hibp, haveibeenpwned
disallow-pwned-passwords
Disallow WordPress and WooCommerce users using pwned passwords
Stars: ✭ 29 (+123.08%)
Mutual labels:  hibp, have-i-been-pwned
Passpwn
See if your passwords in pass has been breached.
Stars: ✭ 130 (+900%)
Mutual labels:  password-safety, haveibeenpwned
Firepwned
🙏 Checks Firefox saved passwords against known data leaks using the Have I Been Pwned API.
Stars: ✭ 69 (+430.77%)
Mutual labels:  password-safety, haveibeenpwned
WWWE
💧 Check your email(s) using popular online services to see if it appears in any data-breach
Stars: ✭ 22 (+69.23%)
Mutual labels:  hibp, breaches
Maltego-haveibeenpwned
Maltego integration of https://haveibeenpwned.com
Stars: ✭ 55 (+323.08%)
Mutual labels:  hibp, haveibeenpwned
laravel-pwned-passwords
Simple Laravel validation rule that allows you to prevent or limit the re-use of passwords that are known to be pwned (unsafe). Based on TroyHunt's Have I Been Pwned (https://haveibeenpwned.com)
Stars: ✭ 67 (+415.38%)
Mutual labels:  password-safety, haveibeenpwned
broom
A disk cleaning utility for developers.
Stars: ✭ 38 (+192.31%)
Mutual labels:  maven
E3Mall
高并发,分布式Java项目,模拟天猫商城,京东商城
Stars: ✭ 33 (+153.85%)
Mutual labels:  maven
wislove
Java 服务端api解决方案,处理部分通用业务逻辑。包括用户中心,支付,订单,IM相关,内容管理,角色权限授权。以及分库分表的处理,RPC分布式的解决方案等。一个人慢慢做
Stars: ✭ 14 (+7.69%)
Mutual labels:  maven
WAPI
The WhatsApp API
Stars: ✭ 36 (+176.92%)
Mutual labels:  maven
maven
Development repository for the maven cookbook
Stars: ✭ 35 (+169.23%)
Mutual labels:  maven
flexmojos-introduction
A gentle introduction to Flexmojos & Maven
Stars: ✭ 50 (+284.62%)
Mutual labels:  maven
jenkins-pipeline-gitflow-maven
Sample Maven project with a Jenkinsfile doing git-flow based release management
Stars: ✭ 47 (+261.54%)
Mutual labels:  maven
pcljava
A port of the Point Cloud Library (PCL) using Java Native Interface (JNI).
Stars: ✭ 19 (+46.15%)
Mutual labels:  maven
cheshuo
🎃A lightweight game server framework. Based on Springboot and Netty. Using ProtoBuf as communication between client and server.
Stars: ✭ 23 (+76.92%)
Mutual labels:  maven
SSM-Maven-Heima
基于SSM(Spring+Springmvc+Mybatis)框架的电商小项目,使用Maven构建项目,MySQL为数据库系统,Redis的缓存服务器(并不是用的很多)。商城分为后台人员管理界面和前台处理服务器两个方面。实现了登录,邮件注册,redis缓存机制,cookie的历史记录浏览,分页浏览商品,加入购物车,提交订单等等功能。最精彩的是,如果你刚刚学完基础的SSM框架,那么你就可以跟着视频一起完成这个很nice的小工程了。话不多说,让我们进入无尽的学习中吧!(光头不再是梦想:) )
Stars: ✭ 106 (+715.38%)
Mutual labels:  maven

haveibeenpwned4j

The ultimate Java library for Troy Hunt's ';-- Have I Been Pwned: API v3.

Build Status Contributors Apache-2.0 Vulnerabilities Coverage

About The Project

Troy Hunt's ';-- Have I Been Pwned is an awesome project that lets you check if you have an account that has been compromised in a data breach.

As you can see on the Consumers page of https://haveibeenpwned.com, there are already Java clients available for the API. Unfortunately some do not fully implement the API or have weird dependencies.

Here comes haveibeenpwned4j awesomeness:

  • All features of ';-- Have I Been Pwned: API v3 implemented (incl. support for providing your API key)
    • Check if a password has been breached
    • Check if an account has been breached
    • Check if an account has been in a paste
    • Get all breaches (or based on a domain)
    • Get a single breach
  • Apache License Version 2.0
  • Available from Maven Central

Getting Started

Prerequisites

Install Java on your system. Java version 11 is the minimum required version

  • Java: Ubuntu
sudo apt install default-jdk
  • Java: Fedora
sudo dnf install java-11-openjdk

Usage

  1. Include the dependency in your pom.xml
<dependency>
  <groupId>de.martinspielmann.haveibeenpwned4j</groupId>
  <artifactId>haveibeenpwned4j</artifactId>
  <version>2.0.0</version>
</dependency>
  1. Create a new HaveIBeenPwnedApiClient and start using it
/**
 * <strong>Watch out:</strong> Authorization is required for all APIs that enable searching HIBP
 * by email address, namely getting breaches for an account, and getting pastes for and account. 
 * An API key is required to make an authorized call and can
 * be obtained on the API key page.
 * 
 * @see https://haveibeenpwned.com/API/v3#Authorisation
 * @see https://haveibeenpwned.com/API/Key
 */
 
HaveIBeenPwnedApiClient client = new HaveIBeenPwnedApiClient("my-super-secret-api-key");

// find out if given password has been breached
boolean isPasswordPwned = client.isPasswordPwned("password123");

// get breaches for an account (needs API key)
List<Breach> breachesByAccount = client.getBreachesForAccount("[email protected]");

// get all breaches
List<Breach> allBreaches = client.getBreaches();

// find breach by name
Breach singleBreach = client.getSingleBreach("Example Breach");

// get pastes for an account (needs API key)
List<Paste> pastes = client.getPastesForAccount("[email protected]");

Contributing

If you have any problem or idea, dont hesitate to report a bug or request a feature.

If you want to help out with some code, tests or documentation, just follow these steps:

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature)
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

Any contributions you make are highly appreciated.

Prepare

Install Apache Maven on your developer system

  • Java and Apache Maven: Ubuntu
sudo apt install maven
  • Java and Apache Maven: Fedora
sudo dnf install maven

Develop

git clone https://github.com/martinspielmann/haveibeenpwned4j.git
cd haveibeenpwned4j

# to make all the tests run, you need to provide your HIBP API key as an environment variable
HIPB_API_KEY=your-super-secret-key && mvn test

Versioning

This project uses Semantic Versioning

License

Distributed under the Apache License Version 2.0. See LICENSE for more information.

Contact

Martin Spielmann - @martspielmann

Project Link: https://github.com/martinspielmann/haveibeenpwned4j

Acknowledgements

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].