# UDdup | Urls De-Duplication Tool For Better Recon

**URL:** <https://onehack.st/t/uddup-urls-de-duplication-tool-for-better-recon/172936>\
**Category:** Tools & Scripts\
**Tags:** tools, hacking, freebies\
**Created:** [February 17, 2021, 11:29am UTC](https://onehack.st/t/uddup-urls-de-duplication-tool-for-better-recon/172936 "2021-02-17T11:29:12Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![NoBody](https://onehack.st/user_avatar/onehack.st/nobody/32/163880_2.png) [@NoBody](https://onehack.st/u/NoBody)\
**Post date:** [February 17, 2021, 11:29am UTC](https://onehack.st/t/uddup-urls-de-duplication-tool-for-better-recon/172936/1 "2021-02-17T11:29:12Z")

</div>

![image](https://onehack.st/uploads/default/original/3X/a/9/a9e7894848f13cb4f22d41c4c4a0ad39ef88e0a7.png)

The tool gets a list of URLs, and removes “duplicate” pages in the sense of URL patterns that are probably repetitive and points to the same web template.

For example:

```auto
https://www.example.com/product/123https://www.example.com/product/456https://www.example.com/product/123?is_prod=falsehttps://www.example.com/product/222?is_debug=true

```

All the above are probably points to the same product “template”. Therefore it should be enough to scan only some of these URLs by our various scanners.

The result of the above after UDdup should be:

```auto
https://www.example.com/product/123?is_prod=falsehttps://www.example.com/product/222?is_debug=true

```

**Why do I need it?**

Mostly for better (automated) reconnaissance process, with less noise (for both the tester and the target).

**Examples**

Take a look at `demo.txt` which is the raw URLs file which results in `demo-results.txt`.

**Installation**

**With pip (Recommended)**

```auto
pip install uddup

```

**Manual (from code)**

```auto
# Clone the repository.git clone https://github.com/rotemreiss/uddup.git# Install the Python requirements.cd udduppip install -r requirements.txt

```

**Usage**

`uddup -u demo.txt -o ./demo-result.txt`

**More Usage Options**

`uddup -h`

| Short Form | Long Form | Description |
| --- | --- | --- |
| -h | –help | Show this help message and exit |
| -u | –urls | File with a list of urls |
| -o | –output | Save results to a file |
| -s | –silent | Print only the result URLs |
| -fp | –filter-path | Filter paths by a given Regex |

**Filter Paths by Regex**

Allows filtering custom paths pattern. For example, if we would like to filter all paths that starts with `/product` we will need to run:

```auto
# Single Regexuddup -u demo.txt -fp "^product"

```

**Input:**

```auto
https://www.example.com/https://www.example.com/privacy-policyhttps://www.example.com/product/1https://www.example2.com/product/2https://www.example3.com/product/4

```

**Output:**

```auto
https://www.example.com/https://www.example.com/privacy-policy

```

**Advanced Regex with multiple path filters**

```auto
uddup -u demo.txt -fp "(^product)|(^category)"

```

**Contributing**

Feel free to fork the repository and submit pull-requests.

**Support**

[Create new GitHub issue](https://github.com/rotemreiss/uddup/issues/new)

Want to say thanks? Message me on [Linkedin](https://www.linkedin.com/in/reissr)

## GitHub:

> **[GitHub - rotemreiss/uddup: Urls de-duplication tool for better recon.](https://github.com/rotemreiss/uddup)**
>
> Urls de-duplication tool for better recon.
