claritynet 1.0.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- claritynet-1.0.0/LICENSE +201 -0
- claritynet-1.0.0/NOTICE +10 -0
- claritynet-1.0.0/PKG-INFO +114 -0
- claritynet-1.0.0/README.md +92 -0
- claritynet-1.0.0/pyproject.toml +40 -0
- claritynet-1.0.0/setup.cfg +4 -0
- claritynet-1.0.0/src/claritynet/__init__.py +26 -0
- claritynet-1.0.0/src/claritynet/__main__.py +6 -0
- claritynet-1.0.0/src/claritynet/actions.py +142 -0
- claritynet-1.0.0/src/claritynet/cli.py +219 -0
- claritynet-1.0.0/src/claritynet/devices.py +89 -0
- claritynet-1.0.0/src/claritynet/names.py +416 -0
- claritynet-1.0.0/src/claritynet/scanner.py +428 -0
- claritynet-1.0.0/src/claritynet/server.py +307 -0
- claritynet-1.0.0/src/claritynet/store.py +308 -0
- claritynet-1.0.0/src/claritynet/system.py +312 -0
- claritynet-1.0.0/src/claritynet/tray.py +177 -0
- claritynet-1.0.0/src/claritynet/vendors.py +75 -0
- claritynet-1.0.0/src/claritynet/web/bar.js +35 -0
- claritynet-1.0.0/src/claritynet/web/base.css +82 -0
- claritynet-1.0.0/src/claritynet/web/claritynet-new.ico +0 -0
- claritynet-1.0.0/src/claritynet/web/claritynet.ico +0 -0
- claritynet-1.0.0/src/claritynet/web/controls.js +238 -0
- claritynet-1.0.0/src/claritynet/web/core.js +361 -0
- claritynet-1.0.0/src/claritynet/web/detail.js +159 -0
- claritynet-1.0.0/src/claritynet/web/extras.css +122 -0
- claritynet-1.0.0/src/claritynet/web/fonts/OFL.txt +93 -0
- claritynet-1.0.0/src/claritynet/web/fonts/inter-latin.woff2 +0 -0
- claritynet-1.0.0/src/claritynet/web/hero.css +96 -0
- claritynet-1.0.0/src/claritynet/web/index.html +186 -0
- claritynet-1.0.0/src/claritynet/web/list.css +165 -0
- claritynet-1.0.0/src/claritynet/web/list.js +242 -0
- claritynet-1.0.0/src/claritynet/web/mobile.css +56 -0
- claritynet-1.0.0/src/claritynet/web/radar.js +199 -0
- claritynet-1.0.0/src/claritynet/web/settings.css +40 -0
- claritynet-1.0.0/src/claritynet/web/settings.js +154 -0
- claritynet-1.0.0/src/claritynet/web/views.css +72 -0
- claritynet-1.0.0/src/claritynet/web/views.js +176 -0
- claritynet-1.0.0/src/claritynet/web/who.css +129 -0
- claritynet-1.0.0/src/claritynet/web/who.js +319 -0
- claritynet-1.0.0/src/claritynet.egg-info/PKG-INFO +114 -0
- claritynet-1.0.0/src/claritynet.egg-info/SOURCES.txt +53 -0
- claritynet-1.0.0/src/claritynet.egg-info/dependency_links.txt +1 -0
- claritynet-1.0.0/src/claritynet.egg-info/entry_points.txt +2 -0
- claritynet-1.0.0/src/claritynet.egg-info/top_level.txt +1 -0
- claritynet-1.0.0/tests/test_actions.py +160 -0
- claritynet-1.0.0/tests/test_cli.py +226 -0
- claritynet-1.0.0/tests/test_devices.py +161 -0
- claritynet-1.0.0/tests/test_names.py +249 -0
- claritynet-1.0.0/tests/test_scanner.py +314 -0
- claritynet-1.0.0/tests/test_server.py +254 -0
- claritynet-1.0.0/tests/test_store.py +338 -0
- claritynet-1.0.0/tests/test_system.py +194 -0
- claritynet-1.0.0/tests/test_tools.py +173 -0
- claritynet-1.0.0/tests/test_tray.py +48 -0
claritynet-1.0.0/LICENSE
ADDED
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
Apache License
|
|
2
|
+
Version 2.0, January 2004
|
|
3
|
+
http://www.apache.org/licenses/
|
|
4
|
+
|
|
5
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
6
|
+
|
|
7
|
+
1. Definitions.
|
|
8
|
+
|
|
9
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
10
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
11
|
+
|
|
12
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
13
|
+
the copyright owner that is granting the License.
|
|
14
|
+
|
|
15
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
16
|
+
other entities that control, are controlled by, or are under common
|
|
17
|
+
control with that entity. For the purposes of this definition,
|
|
18
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
19
|
+
direction or management of such entity, whether by contract or
|
|
20
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
21
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
22
|
+
|
|
23
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
24
|
+
exercising permissions granted by this License.
|
|
25
|
+
|
|
26
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
27
|
+
including but not limited to software source code, documentation
|
|
28
|
+
source, and configuration files.
|
|
29
|
+
|
|
30
|
+
"Object" form shall mean any form resulting from mechanical
|
|
31
|
+
transformation or translation of a Source form, including but
|
|
32
|
+
not limited to compiled object code, generated documentation,
|
|
33
|
+
and conversions to other media types.
|
|
34
|
+
|
|
35
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
36
|
+
Object form, made available under the License, as indicated by a
|
|
37
|
+
copyright notice that is included in or attached to the work
|
|
38
|
+
(an example is provided in the Appendix below).
|
|
39
|
+
|
|
40
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
41
|
+
form, that is based on (or derived from) the Work and for which the
|
|
42
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
43
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
44
|
+
of this License, Derivative Works shall not include works that remain
|
|
45
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
46
|
+
the Work and Derivative Works thereof.
|
|
47
|
+
|
|
48
|
+
"Contribution" shall mean any work of authorship, including
|
|
49
|
+
the original version of the Work and any modifications or additions
|
|
50
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
51
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
52
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
53
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
54
|
+
means any form of electronic, verbal, or written communication sent
|
|
55
|
+
to the Licensor or its representatives, including but not limited to
|
|
56
|
+
communication on electronic mailing lists, source code control systems,
|
|
57
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
58
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
59
|
+
excluding communication that is conspicuously marked or otherwise
|
|
60
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
61
|
+
|
|
62
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
63
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
64
|
+
subsequently incorporated within the Work.
|
|
65
|
+
|
|
66
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
67
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
68
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
69
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
70
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
71
|
+
Work and such Derivative Works in Source or Object form.
|
|
72
|
+
|
|
73
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
74
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
75
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
76
|
+
(except as stated in this section) patent license to make, have made,
|
|
77
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
78
|
+
where such license applies only to those patent claims licensable
|
|
79
|
+
by such Contributor that are necessarily infringed by their
|
|
80
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
81
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
82
|
+
institute patent litigation against any entity (including a
|
|
83
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
84
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
85
|
+
or contributory patent infringement, then any patent licenses
|
|
86
|
+
granted to You under this License for that Work shall terminate
|
|
87
|
+
as of the date such litigation is filed.
|
|
88
|
+
|
|
89
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
90
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
91
|
+
modifications, and in Source or Object form, provided that You
|
|
92
|
+
meet the following conditions:
|
|
93
|
+
|
|
94
|
+
(a) You must give any other recipients of the Work or
|
|
95
|
+
Derivative Works a copy of this License; and
|
|
96
|
+
|
|
97
|
+
(b) You must cause any modified files to carry prominent notices
|
|
98
|
+
stating that You changed the files; and
|
|
99
|
+
|
|
100
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
101
|
+
that You distribute, all copyright, patent, trademark, and
|
|
102
|
+
attribution notices from the Source form of the Work,
|
|
103
|
+
excluding those notices that do not pertain to any part of
|
|
104
|
+
the Derivative Works; and
|
|
105
|
+
|
|
106
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
107
|
+
distribution, then any Derivative Works that You distribute must
|
|
108
|
+
include a readable copy of the attribution notices contained
|
|
109
|
+
within such NOTICE file, excluding those notices that do not
|
|
110
|
+
pertain to any part of the Derivative Works, in at least one
|
|
111
|
+
of the following places: within a NOTICE text file distributed
|
|
112
|
+
as part of the Derivative Works; within the Source form or
|
|
113
|
+
documentation, if provided along with the Derivative Works; or,
|
|
114
|
+
within a display generated by the Derivative Works, if and
|
|
115
|
+
wherever such third-party notices normally appear. The contents
|
|
116
|
+
of the NOTICE file are for informational purposes only and
|
|
117
|
+
do not modify the License. You may add Your own attribution
|
|
118
|
+
notices within Derivative Works that You distribute, alongside
|
|
119
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
120
|
+
that such additional attribution notices cannot be construed
|
|
121
|
+
as modifying the License.
|
|
122
|
+
|
|
123
|
+
You may add Your own copyright statement to Your modifications and
|
|
124
|
+
may provide additional or different license terms and conditions
|
|
125
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
126
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
127
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
128
|
+
the conditions stated in this License.
|
|
129
|
+
|
|
130
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
131
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
132
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
133
|
+
this License, without any additional terms or conditions.
|
|
134
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
135
|
+
the terms of any separate license agreement you may have executed
|
|
136
|
+
with Licensor regarding such Contributions.
|
|
137
|
+
|
|
138
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
139
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
140
|
+
except as required for reasonable and customary use in describing the
|
|
141
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
142
|
+
|
|
143
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
144
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
145
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
146
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
147
|
+
implied, including, without limitation, any warranties or conditions
|
|
148
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
149
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
150
|
+
appropriateness of using or redistributing the Work and assume any
|
|
151
|
+
risks associated with Your exercise of permissions under this License.
|
|
152
|
+
|
|
153
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
154
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
155
|
+
unless required by applicable law (such as deliberate and grossly
|
|
156
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
157
|
+
liable to You for damages, including any direct, indirect, special,
|
|
158
|
+
incidental, or consequential damages of any character arising as a
|
|
159
|
+
result of this License or out of the use or inability to use the
|
|
160
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
161
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
162
|
+
other commercial damages or losses), even if such Contributor
|
|
163
|
+
has been advised of the possibility of such damages.
|
|
164
|
+
|
|
165
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
166
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
167
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
168
|
+
or other liability obligations and/or rights consistent with this
|
|
169
|
+
License. However, in accepting such obligations, You may act only
|
|
170
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
171
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
172
|
+
defend, and hold each Contributor harmless for any liability
|
|
173
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
174
|
+
of your accepting any such warranty or additional liability.
|
|
175
|
+
|
|
176
|
+
END OF TERMS AND CONDITIONS
|
|
177
|
+
|
|
178
|
+
APPENDIX: How to apply the Apache License to your work.
|
|
179
|
+
|
|
180
|
+
To apply the Apache License to your work, attach the following
|
|
181
|
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
182
|
+
replaced with your own identifying information. (Don't include
|
|
183
|
+
the brackets!) The text should be enclosed in the appropriate
|
|
184
|
+
comment syntax for the file format. We also recommend that a
|
|
185
|
+
file or class name and description of purpose be included on the
|
|
186
|
+
same "printed page" as the copyright notice for easier
|
|
187
|
+
identification within third-party archives.
|
|
188
|
+
|
|
189
|
+
Copyright 2026 LucidaraSoft
|
|
190
|
+
|
|
191
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
192
|
+
you may not use this file except in compliance with the License.
|
|
193
|
+
You may obtain a copy of the License at
|
|
194
|
+
|
|
195
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
196
|
+
|
|
197
|
+
Unless required by applicable law or agreed to in writing, software
|
|
198
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
199
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
200
|
+
See the License for the specific language governing permissions and
|
|
201
|
+
limitations under the License.
|
claritynet-1.0.0/NOTICE
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
ClarityNet
|
|
2
|
+
Copyright 2026 LucidaraSoft (https://lucidarasoft.com)
|
|
3
|
+
|
|
4
|
+
This product was created by Oshan Pitigala.
|
|
5
|
+
"ClarityNet", "LucidaraSoft" and "Lucidara" are names of LucidaraSoft. The Apache License
|
|
6
|
+
does not grant permission to use them (see section 6 of the License).
|
|
7
|
+
|
|
8
|
+
This product includes the Inter typeface (src/claritynet/web/fonts/inter-latin.woff2),
|
|
9
|
+
Copyright 2020 The Inter Project Authors (https://github.com/rsms/inter), licensed under the
|
|
10
|
+
SIL Open Font License, Version 1.1 (src/claritynet/web/fonts/OFL.txt).
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: claritynet
|
|
3
|
+
Version: 1.0.0
|
|
4
|
+
Summary: See every device on your network and know which one is which. Private: no account, no cloud.
|
|
5
|
+
Author: Oshan Pitigala
|
|
6
|
+
License-Expression: Apache-2.0
|
|
7
|
+
Project-URL: Homepage, https://lucidarasoft.com
|
|
8
|
+
Project-URL: Repository, https://github.com/lucidarasoft/clarity-net
|
|
9
|
+
Project-URL: Issues, https://github.com/lucidarasoft/clarity-net/issues
|
|
10
|
+
Keywords: network,scanner,lan,wifi,devices,dashboard
|
|
11
|
+
Classifier: Development Status :: 5 - Production/Stable
|
|
12
|
+
Classifier: Environment :: Web Environment
|
|
13
|
+
Classifier: Intended Audience :: End Users/Desktop
|
|
14
|
+
Classifier: Operating System :: OS Independent
|
|
15
|
+
Classifier: Programming Language :: Python :: 3
|
|
16
|
+
Classifier: Topic :: System :: Networking :: Monitoring
|
|
17
|
+
Requires-Python: >=3.8
|
|
18
|
+
Description-Content-Type: text/markdown
|
|
19
|
+
License-File: LICENSE
|
|
20
|
+
License-File: NOTICE
|
|
21
|
+
Dynamic: license-file
|
|
22
|
+
|
|
23
|
+
# ClarityNet
|
|
24
|
+
|
|
25
|
+
**See every device on your network, and know which one is which.**
|
|
26
|
+
A private network scanner with a live dashboard. Free, open source, and nothing leaves your computer.
|
|
27
|
+
By [LucidaraSoft](https://lucidarasoft.com). *Clarity, engineered.*
|
|
28
|
+
|
|
29
|
+
<p>
|
|
30
|
+
<img src="https://raw.githubusercontent.com/lucidarasoft/clarity-net/main/docs/dashboard.png" alt="The ClarityNet dashboard: a radar of devices and the device list" width="72%">
|
|
31
|
+
<img src="https://raw.githubusercontent.com/lucidarasoft/clarity-net/main/docs/find-it.png" alt="Find it on a phone: a tablet was found and named" width="25%">
|
|
32
|
+
</p>
|
|
33
|
+
|
|
34
|
+
## Why ClarityNet
|
|
35
|
+
|
|
36
|
+
- **Private by design.** No account, no cloud, no tracking. Your list stays in one file on your computer.
|
|
37
|
+
- **Names, not numbers.** ClarityNet hears the names phones, TVs and computers give themselves.
|
|
38
|
+
Still not sure? **Find it**: turn a device's Wi-Fi off and on, and ClarityNet points to it.
|
|
39
|
+
- **A live dashboard.** Radar, device list, who is home when, insights and an activity log.
|
|
40
|
+
- **Alerts.** A desktop notice when a new device joins, or a device you watch comes or goes.
|
|
41
|
+
- **Easy to start.** A Windows installer, or plain Python 3.8 or newer with no other software. Windows, macOS and Linux.
|
|
42
|
+
- **Works offline.** The page loads nothing from the internet. The only download is the optional
|
|
43
|
+
maker list (1.4 MB, once, when you ask for it).
|
|
44
|
+
|
|
45
|
+
## Install
|
|
46
|
+
|
|
47
|
+
**Windows:** download `ClarityNet-Setup-<version>.exe` from the [Releases page](https://github.com/lucidarasoft/clarity-net/releases/latest) and run it.
|
|
48
|
+
It needs no administrator rights. It also offers to let ClarityNet through the firewall; that one step asks
|
|
49
|
+
for administrator approval, and the install finishes either way.
|
|
50
|
+
|
|
51
|
+
**Any system with Python 3.8 or newer:**
|
|
52
|
+
|
|
53
|
+
```
|
|
54
|
+
pipx install claritynet
|
|
55
|
+
claritynet
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
No pipx? `pip install claritynet` works too. Or download the one file (see [Downloads](#downloads)) and run
|
|
59
|
+
`python claritynet-<version>.pyz`. Try it first with made-up devices: `claritynet --demo`.
|
|
60
|
+
|
|
61
|
+
Only scan networks you own or have permission to scan.
|
|
62
|
+
|
|
63
|
+
## Use
|
|
64
|
+
|
|
65
|
+
The dashboard opens in your browser and the program keeps scanning while it runs.
|
|
66
|
+
|
|
67
|
+
| Command | What it does |
|
|
68
|
+
|---|---|
|
|
69
|
+
| `claritynet` | Scan and open the dashboard |
|
|
70
|
+
| `claritynet --demo` | Try it with made-up devices |
|
|
71
|
+
| `claritynet --every 5` | Scan every 5 minutes in the background (1, 5 or 15; 0 is off) |
|
|
72
|
+
| `claritynet --internet cloudflare` | Also ping the internet with each scan (`google`, an IP address, or `off`, the default) |
|
|
73
|
+
| `claritynet --startup on` | Start quietly when you sign in (`off` to stop) |
|
|
74
|
+
| `claritynet --save report.html` | Scan once and save a report file |
|
|
75
|
+
| `claritynet --port 9000` | Use another port for the dashboard (the default is 8765) |
|
|
76
|
+
| `claritynet --subnet 192.168.1.0/24` | Scan this range (useful when a VPN is on) |
|
|
77
|
+
| `claritynet --help` | Show all options |
|
|
78
|
+
|
|
79
|
+
Run the same command again to open the page: only one copy runs at a time.
|
|
80
|
+
To stop it, click **Quit** in Settings (the gear).
|
|
81
|
+
|
|
82
|
+
On Windows, ClarityNet also has an icon in the taskbar's notification area. Hover it for the device count,
|
|
83
|
+
click it to open the page, right-click it to scan now or quit. A small orange dot on it means new devices joined.
|
|
84
|
+
|
|
85
|
+
## Good to know
|
|
86
|
+
|
|
87
|
+
- **Allow it through the firewall.** If Windows or macOS asks whether Python may use the network, click
|
|
88
|
+
**Allow**. That lets ClarityNet hear the names devices give when they join.
|
|
89
|
+
- **Linux:** hearing those names needs administrator rights. Everything else works without them.
|
|
90
|
+
- **Windows SmartScreen** may say it doesn't know the installer yet. Choose **More info**, then **Run anyway**.
|
|
91
|
+
This goes away once the installer is signed.
|
|
92
|
+
- **Your data** stays in `%LOCALAPPDATA%\claritynet` (Windows), `~/Library/Caches/claritynet` (macOS)
|
|
93
|
+
or `~/.cache/claritynet` (Linux). Settings shows the exact place.
|
|
94
|
+
|
|
95
|
+
## Downloads
|
|
96
|
+
|
|
97
|
+
Every release is on the [Releases page](https://github.com/lucidarasoft/clarity-net/releases/latest), named with its version:
|
|
98
|
+
|
|
99
|
+
| File | For |
|
|
100
|
+
|---|---|
|
|
101
|
+
| `ClarityNet-Setup-<version>.exe` | Windows: the app with its own Python, Start menu entry and uninstaller |
|
|
102
|
+
| `claritynet-<version>.pyz` | One file, no install: `python claritynet-<version>.pyz` |
|
|
103
|
+
| `claritynet-<version>-py3-none-any.whl` | Installing with pip, offline |
|
|
104
|
+
| `claritynet-<version>.tar.gz` | The source code |
|
|
105
|
+
|
|
106
|
+
Each release shows its build ID too. ClarityNet shows the same ID in Settings > About.
|
|
107
|
+
|
|
108
|
+
## Contributing
|
|
109
|
+
|
|
110
|
+
Bug reports and pull requests are welcome. See [CONTRIBUTING.md](https://github.com/lucidarasoft/clarity-net/blob/main/CONTRIBUTING.md) for building, testing and releases.
|
|
111
|
+
|
|
112
|
+
## License
|
|
113
|
+
|
|
114
|
+
Apache License 2.0. See [LICENSE](https://github.com/lucidarasoft/clarity-net/blob/main/LICENSE) and [NOTICE](https://github.com/lucidarasoft/clarity-net/blob/main/NOTICE). Copyright 2026 LucidaraSoft.
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
# ClarityNet
|
|
2
|
+
|
|
3
|
+
**See every device on your network, and know which one is which.**
|
|
4
|
+
A private network scanner with a live dashboard. Free, open source, and nothing leaves your computer.
|
|
5
|
+
By [LucidaraSoft](https://lucidarasoft.com). *Clarity, engineered.*
|
|
6
|
+
|
|
7
|
+
<p>
|
|
8
|
+
<img src="https://raw.githubusercontent.com/lucidarasoft/clarity-net/main/docs/dashboard.png" alt="The ClarityNet dashboard: a radar of devices and the device list" width="72%">
|
|
9
|
+
<img src="https://raw.githubusercontent.com/lucidarasoft/clarity-net/main/docs/find-it.png" alt="Find it on a phone: a tablet was found and named" width="25%">
|
|
10
|
+
</p>
|
|
11
|
+
|
|
12
|
+
## Why ClarityNet
|
|
13
|
+
|
|
14
|
+
- **Private by design.** No account, no cloud, no tracking. Your list stays in one file on your computer.
|
|
15
|
+
- **Names, not numbers.** ClarityNet hears the names phones, TVs and computers give themselves.
|
|
16
|
+
Still not sure? **Find it**: turn a device's Wi-Fi off and on, and ClarityNet points to it.
|
|
17
|
+
- **A live dashboard.** Radar, device list, who is home when, insights and an activity log.
|
|
18
|
+
- **Alerts.** A desktop notice when a new device joins, or a device you watch comes or goes.
|
|
19
|
+
- **Easy to start.** A Windows installer, or plain Python 3.8 or newer with no other software. Windows, macOS and Linux.
|
|
20
|
+
- **Works offline.** The page loads nothing from the internet. The only download is the optional
|
|
21
|
+
maker list (1.4 MB, once, when you ask for it).
|
|
22
|
+
|
|
23
|
+
## Install
|
|
24
|
+
|
|
25
|
+
**Windows:** download `ClarityNet-Setup-<version>.exe` from the [Releases page](https://github.com/lucidarasoft/clarity-net/releases/latest) and run it.
|
|
26
|
+
It needs no administrator rights. It also offers to let ClarityNet through the firewall; that one step asks
|
|
27
|
+
for administrator approval, and the install finishes either way.
|
|
28
|
+
|
|
29
|
+
**Any system with Python 3.8 or newer:**
|
|
30
|
+
|
|
31
|
+
```
|
|
32
|
+
pipx install claritynet
|
|
33
|
+
claritynet
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
No pipx? `pip install claritynet` works too. Or download the one file (see [Downloads](#downloads)) and run
|
|
37
|
+
`python claritynet-<version>.pyz`. Try it first with made-up devices: `claritynet --demo`.
|
|
38
|
+
|
|
39
|
+
Only scan networks you own or have permission to scan.
|
|
40
|
+
|
|
41
|
+
## Use
|
|
42
|
+
|
|
43
|
+
The dashboard opens in your browser and the program keeps scanning while it runs.
|
|
44
|
+
|
|
45
|
+
| Command | What it does |
|
|
46
|
+
|---|---|
|
|
47
|
+
| `claritynet` | Scan and open the dashboard |
|
|
48
|
+
| `claritynet --demo` | Try it with made-up devices |
|
|
49
|
+
| `claritynet --every 5` | Scan every 5 minutes in the background (1, 5 or 15; 0 is off) |
|
|
50
|
+
| `claritynet --internet cloudflare` | Also ping the internet with each scan (`google`, an IP address, or `off`, the default) |
|
|
51
|
+
| `claritynet --startup on` | Start quietly when you sign in (`off` to stop) |
|
|
52
|
+
| `claritynet --save report.html` | Scan once and save a report file |
|
|
53
|
+
| `claritynet --port 9000` | Use another port for the dashboard (the default is 8765) |
|
|
54
|
+
| `claritynet --subnet 192.168.1.0/24` | Scan this range (useful when a VPN is on) |
|
|
55
|
+
| `claritynet --help` | Show all options |
|
|
56
|
+
|
|
57
|
+
Run the same command again to open the page: only one copy runs at a time.
|
|
58
|
+
To stop it, click **Quit** in Settings (the gear).
|
|
59
|
+
|
|
60
|
+
On Windows, ClarityNet also has an icon in the taskbar's notification area. Hover it for the device count,
|
|
61
|
+
click it to open the page, right-click it to scan now or quit. A small orange dot on it means new devices joined.
|
|
62
|
+
|
|
63
|
+
## Good to know
|
|
64
|
+
|
|
65
|
+
- **Allow it through the firewall.** If Windows or macOS asks whether Python may use the network, click
|
|
66
|
+
**Allow**. That lets ClarityNet hear the names devices give when they join.
|
|
67
|
+
- **Linux:** hearing those names needs administrator rights. Everything else works without them.
|
|
68
|
+
- **Windows SmartScreen** may say it doesn't know the installer yet. Choose **More info**, then **Run anyway**.
|
|
69
|
+
This goes away once the installer is signed.
|
|
70
|
+
- **Your data** stays in `%LOCALAPPDATA%\claritynet` (Windows), `~/Library/Caches/claritynet` (macOS)
|
|
71
|
+
or `~/.cache/claritynet` (Linux). Settings shows the exact place.
|
|
72
|
+
|
|
73
|
+
## Downloads
|
|
74
|
+
|
|
75
|
+
Every release is on the [Releases page](https://github.com/lucidarasoft/clarity-net/releases/latest), named with its version:
|
|
76
|
+
|
|
77
|
+
| File | For |
|
|
78
|
+
|---|---|
|
|
79
|
+
| `ClarityNet-Setup-<version>.exe` | Windows: the app with its own Python, Start menu entry and uninstaller |
|
|
80
|
+
| `claritynet-<version>.pyz` | One file, no install: `python claritynet-<version>.pyz` |
|
|
81
|
+
| `claritynet-<version>-py3-none-any.whl` | Installing with pip, offline |
|
|
82
|
+
| `claritynet-<version>.tar.gz` | The source code |
|
|
83
|
+
|
|
84
|
+
Each release shows its build ID too. ClarityNet shows the same ID in Settings > About.
|
|
85
|
+
|
|
86
|
+
## Contributing
|
|
87
|
+
|
|
88
|
+
Bug reports and pull requests are welcome. See [CONTRIBUTING.md](https://github.com/lucidarasoft/clarity-net/blob/main/CONTRIBUTING.md) for building, testing and releases.
|
|
89
|
+
|
|
90
|
+
## License
|
|
91
|
+
|
|
92
|
+
Apache License 2.0. See [LICENSE](https://github.com/lucidarasoft/clarity-net/blob/main/LICENSE) and [NOTICE](https://github.com/lucidarasoft/clarity-net/blob/main/NOTICE). Copyright 2026 LucidaraSoft.
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["setuptools>=77"]
|
|
3
|
+
build-backend = "setuptools.build_meta"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "claritynet"
|
|
7
|
+
dynamic = ["version"]
|
|
8
|
+
description = "See every device on your network and know which one is which. Private: no account, no cloud."
|
|
9
|
+
readme = "README.md"
|
|
10
|
+
requires-python = ">=3.8"
|
|
11
|
+
dependencies = []
|
|
12
|
+
license = "Apache-2.0"
|
|
13
|
+
license-files = ["LICENSE", "NOTICE"]
|
|
14
|
+
authors = [{ name = "Oshan Pitigala" }]
|
|
15
|
+
keywords = ["network", "scanner", "lan", "wifi", "devices", "dashboard"]
|
|
16
|
+
classifiers = [
|
|
17
|
+
"Development Status :: 5 - Production/Stable",
|
|
18
|
+
"Environment :: Web Environment",
|
|
19
|
+
"Intended Audience :: End Users/Desktop",
|
|
20
|
+
"Operating System :: OS Independent",
|
|
21
|
+
"Programming Language :: Python :: 3",
|
|
22
|
+
"Topic :: System :: Networking :: Monitoring",
|
|
23
|
+
]
|
|
24
|
+
|
|
25
|
+
[project.urls]
|
|
26
|
+
Homepage = "https://lucidarasoft.com"
|
|
27
|
+
Repository = "https://github.com/lucidarasoft/clarity-net"
|
|
28
|
+
Issues = "https://github.com/lucidarasoft/clarity-net/issues"
|
|
29
|
+
|
|
30
|
+
[project.scripts]
|
|
31
|
+
claritynet = "claritynet.cli:main"
|
|
32
|
+
|
|
33
|
+
[tool.setuptools.dynamic]
|
|
34
|
+
version = { attr = "claritynet.__version__" }
|
|
35
|
+
|
|
36
|
+
[tool.setuptools.packages.find]
|
|
37
|
+
where = ["src"]
|
|
38
|
+
|
|
39
|
+
[tool.setuptools.package-data]
|
|
40
|
+
claritynet = ["web/*", "web/fonts/*"]
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
# ClarityNet by LucidaraSoft (https://lucidarasoft.com)
|
|
2
|
+
# Author: Oshan Pitigala
|
|
3
|
+
# SPDX-License-Identifier: Apache-2.0
|
|
4
|
+
"""ClarityNet: see every device on your local network (Wi-Fi or cable) in a live dashboard.
|
|
5
|
+
|
|
6
|
+
python run.py scan, then open the dashboard in your browser
|
|
7
|
+
python run.py --save devices.html scan once and write a standalone HTML report
|
|
8
|
+
python run.py --subnet 192.168.1.0/24 scan a specific range
|
|
9
|
+
python run.py --demo preview the dashboard with made-up devices
|
|
10
|
+
python run.py --every 5 also scan in the background every 5 minutes
|
|
11
|
+
python run.py --port 9000 use another dashboard port (default 8765)
|
|
12
|
+
python run.py --startup on start quietly at sign-in (Windows, macOS, Linux)
|
|
13
|
+
|
|
14
|
+
When installed (pip install .), the same works as: claritynet [options]
|
|
15
|
+
Needs Python 3.8+ and nothing else. Works on Windows, macOS and Linux.
|
|
16
|
+
Only scan networks you own or have permission to scan.
|
|
17
|
+
"""
|
|
18
|
+
|
|
19
|
+
__version__ = "1.0.0" # MAJOR.MINOR; a release sets the patch from the git tags (tools/version.py)
|
|
20
|
+
__build__ = "261201-1946-run2.1" # the release's build ID, for example "261116-0231-run57.1"; empty from source
|
|
21
|
+
__author__ = "Oshan Pitigala"
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
def version_text():
|
|
25
|
+
"""'1.2.3 (build 261116-0231-run57.1)' for a release, '1.0.dev0' from source."""
|
|
26
|
+
return f"{__version__} (build {__build__})" if __build__ else __version__
|
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
# ClarityNet by LucidaraSoft (https://lucidarasoft.com)
|
|
2
|
+
# Author: Oshan Pitigala
|
|
3
|
+
# SPDX-License-Identifier: Apache-2.0
|
|
4
|
+
"""Things done to or for a device: live check, Wake-on-LAN, desktop alerts, open files, start at sign-in."""
|
|
5
|
+
|
|
6
|
+
import os
|
|
7
|
+
import plistlib
|
|
8
|
+
import re
|
|
9
|
+
import socket
|
|
10
|
+
import subprocess
|
|
11
|
+
import sys
|
|
12
|
+
import threading
|
|
13
|
+
from pathlib import Path
|
|
14
|
+
|
|
15
|
+
from .system import NO_WINDOW, SYSTEM, ScanError, knock, ping, run
|
|
16
|
+
|
|
17
|
+
DEFAULT_PORT = 8765 # the dashboard's usual port (--port changes it)
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
def probe(ip, rounds=3):
|
|
21
|
+
"""Check one device right now, a few times: a ping, or when it ignores pings, a knock on a
|
|
22
|
+
port that phones, web pages and file sharing listen on."""
|
|
23
|
+
results = []
|
|
24
|
+
for _ in range(rounds):
|
|
25
|
+
reply = ping(ip)
|
|
26
|
+
if reply:
|
|
27
|
+
results.append({"ms": reply[0], "how": "ping"})
|
|
28
|
+
continue
|
|
29
|
+
took = next((ms for state, ms in (knock(ip, port, timeout=0.35) for port in (62078, 80, 443)) if state), None)
|
|
30
|
+
results.append({"ms": took, "how": "port" if took is not None else ""})
|
|
31
|
+
return results
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
def desktop_notify(title, body):
|
|
35
|
+
"""Show a system notification, in the background. Quietly does nothing where it isn't supported.
|
|
36
|
+
On Windows the text travels in environment variables, never inside the script."""
|
|
37
|
+
if SYSTEM == "Windows":
|
|
38
|
+
script = ("[Windows.UI.Notifications.ToastNotificationManager, Windows.UI.Notifications, ContentType = WindowsRuntime] | Out-Null;"
|
|
39
|
+
"$x = [Windows.UI.Notifications.ToastNotificationManager]::GetTemplateContent("
|
|
40
|
+
"[Windows.UI.Notifications.ToastTemplateType]::ToastText02);"
|
|
41
|
+
"$t = $x.GetElementsByTagName('text');"
|
|
42
|
+
"$t.Item(0).AppendChild($x.CreateTextNode($env:CLARITYNET_TITLE)) | Out-Null;"
|
|
43
|
+
"$t.Item(1).AppendChild($x.CreateTextNode($env:CLARITYNET_BODY)) | Out-Null;"
|
|
44
|
+
"$app = '{1AC14E77-02E7-4E5D-B744-2EB1AE5198B7}\\WindowsPowerShell\\v1.0\\powershell.exe';"
|
|
45
|
+
"[Windows.UI.Notifications.ToastNotificationManager]::CreateToastNotifier($app).Show("
|
|
46
|
+
"[Windows.UI.Notifications.ToastNotification]::new($x))")
|
|
47
|
+
cmd = ["powershell", "-NoProfile", "-NonInteractive", "-Command", script]
|
|
48
|
+
elif SYSTEM == "Darwin":
|
|
49
|
+
cmd = ["osascript", "-e", "on run argv", "-e", "display notification (item 2 of argv) with title (item 1 of argv)",
|
|
50
|
+
"-e", "end run", title, body]
|
|
51
|
+
else:
|
|
52
|
+
cmd = ["notify-send", title, body]
|
|
53
|
+
env = dict(os.environ, CLARITYNET_TITLE=title, CLARITYNET_BODY=body)
|
|
54
|
+
threading.Thread(target=run, args=(cmd,), kwargs={"timeout": 30, "env": env}, daemon=True).start()
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
def open_on_computer(ip, what):
|
|
58
|
+
"""Open a device's shared files or a remote desktop session on this computer."""
|
|
59
|
+
if what == "files":
|
|
60
|
+
cmd = ["explorer", f"\\\\{ip}"] if SYSTEM == "Windows" else ["open" if SYSTEM == "Darwin" else "xdg-open", f"smb://{ip}"]
|
|
61
|
+
elif what == "rdp" and SYSTEM == "Windows":
|
|
62
|
+
cmd = ["mstsc", f"/v:{ip}"]
|
|
63
|
+
else:
|
|
64
|
+
raise ValueError
|
|
65
|
+
try:
|
|
66
|
+
subprocess.Popen(cmd, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL, stdin=subprocess.DEVNULL,
|
|
67
|
+
creationflags=NO_WINDOW)
|
|
68
|
+
except OSError:
|
|
69
|
+
raise ScanError("This computer couldn't open that.") from None
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
def startup_file():
|
|
73
|
+
"""Where the sign-in entry lives: Windows Startup folder, macOS LaunchAgents, Linux (XDG) autostart."""
|
|
74
|
+
home = Path.home()
|
|
75
|
+
if SYSTEM == "Windows":
|
|
76
|
+
roaming = Path(os.environ.get("APPDATA") or home / "AppData" / "Roaming")
|
|
77
|
+
return roaming / "Microsoft" / "Windows" / "Start Menu" / "Programs" / "Startup" / "ClarityNet.cmd"
|
|
78
|
+
if SYSTEM == "Darwin":
|
|
79
|
+
return home / "Library" / "LaunchAgents" / "com.lucidarasoft.claritynet.plist"
|
|
80
|
+
return Path(os.environ.get("XDG_CONFIG_HOME") or home / ".config") / "autostart" / "claritynet.desktop"
|
|
81
|
+
|
|
82
|
+
|
|
83
|
+
def startup_enabled():
|
|
84
|
+
return startup_file().exists()
|
|
85
|
+
|
|
86
|
+
|
|
87
|
+
def launch_command(port=DEFAULT_PORT):
|
|
88
|
+
"""The command that starts ClarityNet quietly on `port`, with no browser and (on Windows) no console window."""
|
|
89
|
+
python = Path(sys.executable)
|
|
90
|
+
if SYSTEM == "Windows" and python.with_name("pythonw.exe").exists():
|
|
91
|
+
python = python.with_name("pythonw.exe")
|
|
92
|
+
here = Path(__file__).resolve().parents
|
|
93
|
+
if getattr(sys, "frozen", False): # the Windows app: ClarityNet.exe is the program
|
|
94
|
+
start = []
|
|
95
|
+
elif here[1].is_file(): # inside claritynet.pyz: run that file
|
|
96
|
+
start = [str(here[1])]
|
|
97
|
+
elif (here[2] / "run.py").exists(): # a checkout: src/claritynet -> run.py
|
|
98
|
+
start = [str(here[2] / "run.py")]
|
|
99
|
+
else: # installed with pip or pipx
|
|
100
|
+
start = ["-m", "claritynet"]
|
|
101
|
+
port_args = [] if port == DEFAULT_PORT else ["--port", str(port)]
|
|
102
|
+
return [str(python), *start, "--no-browser", *port_args]
|
|
103
|
+
|
|
104
|
+
|
|
105
|
+
def desktop_exec(cmd):
|
|
106
|
+
"""An Exec= value (freedesktop Desktop Entry spec). Each argument is quoted, with " ` $ and \\ escaped;
|
|
107
|
+
then the whole value is escaped again as a string (\\ doubled), and % is doubled (it starts a field code)."""
|
|
108
|
+
quoted = " ".join('"' + re.sub(r'(["`$\\])', r"\\\1", part) + '"' for part in cmd)
|
|
109
|
+
return quoted.replace("\\", "\\\\").replace("%", "%%")
|
|
110
|
+
|
|
111
|
+
|
|
112
|
+
def set_startup(on, port=DEFAULT_PORT):
|
|
113
|
+
"""Start ClarityNet quietly on `port` when you sign in, or stop doing that. Returns what was done."""
|
|
114
|
+
entry = startup_file()
|
|
115
|
+
if not on:
|
|
116
|
+
entry.unlink(missing_ok=True)
|
|
117
|
+
return f"Removed {entry}"
|
|
118
|
+
cmd = launch_command(port)
|
|
119
|
+
if SYSTEM == "Windows": # a batch file: % starts a variable, so it is doubled
|
|
120
|
+
text = '@start "" ' + " ".join(f'"{part}"' for part in cmd).replace("%", "%%") + "\r\n"
|
|
121
|
+
elif SYSTEM == "Darwin":
|
|
122
|
+
text = plistlib.dumps({"Label": "com.lucidarasoft.claritynet", "ProgramArguments": cmd, "RunAtLoad": True}).decode("utf-8")
|
|
123
|
+
else:
|
|
124
|
+
text = ("[Desktop Entry]\nType=Application\nName=ClarityNet\nComment=See every device on your local network\n"
|
|
125
|
+
f"Exec={desktop_exec(cmd)}\nNoDisplay=true\nX-GNOME-Autostart-enabled=true\n")
|
|
126
|
+
entry.parent.mkdir(parents=True, exist_ok=True)
|
|
127
|
+
with entry.open("w", encoding="utf-8", newline="") as file: # Path.write_text has no newline before 3.10
|
|
128
|
+
file.write(text)
|
|
129
|
+
return f"Added {entry}"
|
|
130
|
+
|
|
131
|
+
|
|
132
|
+
def wake(mac, broadcast):
|
|
133
|
+
"""Send a Wake-on-LAN "magic packet": six 0xFF bytes, then the hardware address 16 times."""
|
|
134
|
+
packet = b"\xff" * 6 + bytes.fromhex(mac.replace(":", "")) * 16
|
|
135
|
+
with socket.socket(socket.AF_INET, socket.SOCK_DGRAM) as sock:
|
|
136
|
+
sock.setsockopt(socket.SOL_SOCKET, socket.SO_BROADCAST, 1)
|
|
137
|
+
for target in {broadcast, "255.255.255.255"} - {""}:
|
|
138
|
+
for port in (9, 7):
|
|
139
|
+
try:
|
|
140
|
+
sock.sendto(packet, (target, port))
|
|
141
|
+
except OSError:
|
|
142
|
+
pass
|