splits a URL into individual components, unescapes arguments, and performs light calculations for manual or automated analysis
Project description
URLBreakdown
splits a URL into individual components, unescapes arguments, and performs light calculations for manual or automated analysis
Installation
pip install urlbreakdown
Usage
URLBreakdown("url", pguid=None, verbose=False)
- default is just a URL, with no parent GUID, in non-verbose mode
- include a parent GUID/UUID if generated in the script calling this module
- verbose includes a simple character frequency map, and an additional array-of-nested-arrays of parameters
from urlbreakdown import URLBreakdown
u = URLBreakdown("https://search.yahoo.com/search?p=google&fr=yfp-t&ei=UTF-8&fp=1&blank1=&blank2=")
print(u.json)
#
# optional arguments pguid and verbose
#
u = URLBreakdown("https://search.yahoo.com/search?p=google&fr=yfp-t&ei=UTF-8&fp=1&blank1=&blank2=", pguid="1234-5678-9001", verbose=True)
Available Attributes
json (string)
output (dictionary)
Example Output (via test-urlbreakdown-usage-example.py)
{
"@timestamp": "2021-04-28T19:46:38.144Z",
"guid": "be9fc53e-04a1-4ec9-b382-5a3ef7704039",
"url": {
"full": "https://www.google.com/search?client=firefox-b-1-d&q=reddit&a=%3Cscript%3Ealert%281%29%3B%3C%2Fscript%3E",
"len": 104,
"original": "https://www.google.com/search?client=firefox-b-1-d&q=reddit&a=%3Cscript%3Ealert%281%29%3B%3C%2Fscript%3E",
"dot_count_url": 2,
"scheme": "https",
"domain": "www.google.com",
"dot_count_domain": 2,
"query": "client=firefox-b-1-d&q=reddit&a=%3Cscript%3Ealert%281%29%3B%3C%2Fscript%3E",
"query_len": 74,
"path": "/search",
"unquoted": {
"query": "client=firefox-b-1-d&q=reddit&a=<script>alert(1);</script>",
"query_len": 58
},
"parameters": {
"keys": [
"a",
"q",
"client"
],
"values": [
"reddit",
"<script>alert(1)",
"firefox-b-1-d",
"<script>alert(1);</script>"
],
...
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
urlbreakdown-0.1.1.tar.gz
(5.0 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file urlbreakdown-0.1.1.tar.gz.
File metadata
- Download URL: urlbreakdown-0.1.1.tar.gz
- Upload date:
- Size: 5.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/3.7.3 pkginfo/1.7.0 requests/2.22.0 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.6.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f02883287e8dd221513829f4b51ad69f837c7c6bdabbc2922f37bbb0386391fc
|
|
| MD5 |
7c9e3781c07fc2f17c7210c58b552047
|
|
| BLAKE2b-256 |
88ef8173fc559ff63b3fbec40fa3a5c261eca516d50fb4bee6386337b28c379c
|
File details
Details for the file urlbreakdown-0.1.1-py3-none-any.whl.
File metadata
- Download URL: urlbreakdown-0.1.1-py3-none-any.whl
- Upload date:
- Size: 5.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/3.7.3 pkginfo/1.7.0 requests/2.22.0 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.6.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4c484d0334e87076d7a5ba39da84fa060bb66a155247dfa90313bbca561378a2
|
|
| MD5 |
b9f6c764f1752a8515d4e9841446866b
|
|
| BLAKE2b-256 |
6df1871250c114fc98f1b7d01a6ff546eda55b3a6560f563f444acd16aa550b4
|