Skip to content

Commit

Permalink
feat: add Pipl support
Browse files Browse the repository at this point in the history
  • Loading branch information
ninoseki committed Sep 1, 2018
1 parent c8ba08c commit 44c988b
Show file tree
Hide file tree
Showing 6 changed files with 35 additions and 2 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ Note: `email` type IOC is used for reverse WHOIS lookup.
| FindSubDomains | https://findsubdomains.com | domain |
| HybridAnalysis | https://www.hybrid-analysis.com | hash (sha256 only) |
| ONYPHE | https://www.onyphe.io | ip |
| Pipl | https://pipl.com | email |
| PublicWWW | https://publicwww.com | text |
| Pulsedive | https://pulsedive.com | ip / domaion / url / hash |
| RiskIQ | http://community.riskiq.com | ip / domain / email |
Expand Down
1 change: 1 addition & 0 deletions src/lib/searcher/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ export { DomainBigData } from "./domainbigdata";
export { FindSubDomains } from "./findsubdomains";
export { HybridAnalysis } from "./hybridanalysis";
export { ONYPHE } from "./onyphe";
export { Pipl } from "./pipl";
export { PublicWWW } from "./publicwww";
export { Pulsedive } from "./pulsedive";
export { RiskIQ } from "./riskiq";
Expand Down
17 changes: 17 additions & 0 deletions src/lib/searcher/pipl.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import { Searcher } from "./searcher";

export class Pipl implements Searcher {

public endpoint: string;
public name;
public supportedTypes: string[] = ["email"];

constructor() {
this.endpoint = "https://pipl.com"
this.name = "Pipl";
}

public searchByEmail(query) {
return `${this.endpoint}/search/?q=${encodeURIComponent(query)}`;
}
}
2 changes: 2 additions & 0 deletions src/lib/searcher/searchers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import {
FindSubDomains,
HybridAnalysis,
ONYPHE,
Pipl,
PublicWWW,
Pulsedive,
RiskIQ,
Expand All @@ -26,6 +27,7 @@ export const Searchers: Searcher[] = [
new FindSubDomains(),
new HybridAnalysis(),
new ONYPHE(),
new Pipl(),
new PublicWWW(),
new Pulsedive(),
new RiskIQ(),
Expand Down
12 changes: 12 additions & 0 deletions src/spec/searcher/pipl.spec.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import { expect } from "chai";
import "mocha";
import { Pipl } from "../../lib/searcher";

describe("Pipl", () => {
describe("#searchByEmail", () => {
it("should return URL", () => {
const pipl = new Pipl();
expect(pipl.searchByEmail("test@test.com")).to.equal("https://pipl.com/search/?q=test%40test.com");
});
});
});
4 changes: 2 additions & 2 deletions src/spec/selector.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ describe("Seletor", () => {
text: 3,
// urlscan, pulsedive, virustotal
url: 3,
// viewDNS, threatcrowd, riskiq
email: 3,
// viewDNS, threatcrowd, riskiq, pipl
email: 4,
};

context("searcher", () => {
Expand Down

0 comments on commit 44c988b

Please sign in to comment.