Compare commits

..

No commits in common. "main" and "main" have entirely different histories.
main ... main

14 changed files with 62 additions and 568 deletions

View File

@ -25,10 +25,7 @@ sub startup ($self) {
$r->get('/')->to('Main#index');
$r->get('/index.html')->to('Main#index');
$r->get('/rules')->to('Main#rules');
my $svc = $r->any('/services')->to(controller => 'Services');
$svc->get('/')->to(action => 'index');
$svc->get('/bridges')->to(action => 'bridges');
$r->get('/services')->to('Main#services');
$r->get('/register')->to('Register#registration');
$r->post('/register')->to('Register#register');

View File

@ -19,6 +19,11 @@ sub rules ($self) {
$self->render();
}
sub services ($self) {
$self->render();
}
my $cache = Mojo::Cache->new(max_keys => 1);
$cache->set(users => []);
Mojo::IOLoop->recurring(60 => sub {
@ -156,7 +161,7 @@ sub announcement_feed ($self) {
}
my $announcements = $acache->get('announcements');
my @chosen = sort { $b cmp $a } (keys %$announcements);
my @chosen = sort (keys %$announcements);
if (scalar(@chosen) > 5) {
@chosen = @chosen[0..4];

View File

@ -1,16 +0,0 @@
package unix_dog::Controller::Services;
use strict;
use warnings FATAL => 'all';
use experimental 'signatures';
use Mojo::Base 'Mojolicious::Controller', -signatures;
sub index($c) {
$c->render();
}
sub bridges($c) {
$c->render();
}
1;

View File

@ -9,7 +9,7 @@ body {
min-height: 100vh;
}
h2 {
h1, h2 {
color: #4af626;
}
@ -37,7 +37,7 @@ a:visited {
color: #211c1b;
}
h2 {
h1, h2 {
color: #4c982a;
}
@ -171,7 +171,7 @@ label.field-with-error {
color: red;
}
.stats {
img.stats {
width: 100%;
display: block;
}

View File

@ -1,48 +0,0 @@
// Load netDiv.
const netDiv = document.getElementById("net-stats");
// Enter async context. Makes things easier.
(async function() {
// Fetch JSON
const netDataReq = await fetch("/net-in.json");
const netData = await netDataReq.json();
// Get list of entries
const legends = netData.meta.legend;
// Holds the plotly.JS data
const data = [];
// Create date objects for x-axis
const x = netData.data.map(a => new Date(a[0] * 1e3));
// Iterate through legends, fill up data.
for (let i = 0; i < legends.length; i++) {
const name = legends[i];
const y = netData.data.map(a => a[i+1]);
// Add data entry to array.
data.push({
x,
y,
name,
type: "bar",
});
}
// Format
const layout = {
barmode: "stack",
title: {
text: "Traffic In",
},
yaxis: {
title: {
text: "Bytes/S",
},
},
};
// Create plot
Plotly.newPlot(netDiv, data, layout);
})()

File diff suppressed because one or more lines are too long

View File

@ -1,16 +0,0 @@
/*
* @copyright 2016 Sean Connelly (@voidqk), http://syntheti.cc
* @license MIT
* @preserve Project Home: https://github.com/voidqk/polybooljs
*/
/*
object-assign
(c) Sindre Sorhus
@license MIT
*/
/*! Native Promise Only
v0.8.1 (c) Kyle Simpson
MIT License: http://getify.mit-license.org
*/

View File

@ -14,7 +14,7 @@
</image>
% foreach my $item (@$items) {
<item>
<title><![CDATA[<%== $item->{'title'} %>]]></title>
<title><![CDATA[<%= $item->{'title'} %>]]></title>
<link><%= $item->{'url'} %></link>
<guid isPermaLink="true"><%= $item->{'url'} %></guid>
<description><![CDATA[<%== $item->{'text'} %>]]></description>

View File

@ -59,12 +59,6 @@
pay it forward! Donate to your favorite charity and support the causes
you believe in.
</p>
<p>
This server is also reachable via Tor, I2P, and Yggdrasil
networks. The Tor address is <a href="http://unixdoggmgze3fd5hzkqz43izjgxyupjnqsptke53qrcbhl624d7xcyd.onion">unixdoggmgze3fd5hzkqz43izjgxyupjnqsptke53qrcbhl624d7xcyd.onion</a>,
the I2P address is <a href="http://i2pdog7zywdhbtoxf36zqawbvhvucgnwotgjshwnvcjkwrvrahva.b32.i2p">i2pdog7zywdhbtoxf36zqawbvhvucgnwotgjshwnvcjkwrvrahva.b32.i2p</a>,
and the Yggdrasil address is 200:9ab4:427b:6860:5f2b:7e58:741a:115d (or simply y.unix.dog).
</p>
<p>
If you do want to donate, you can do so via XMR or BTC:
</p>

View File

@ -6,7 +6,7 @@
To provide a welcoming space, UNIX.dog needs some rules. (tl;dr don't be an asshole).
</p>
<p>
Please keep in mind that final interpretation of these rules are up to UNIX.dog admins.
Please keep in mind that final intepretation of these rules are up to UNIX.dog admins.
As the server is hosted in St. Louis, United States, by Contabo, all use of UNIX.dog services
must follow federal law of the U.S. and the
<a href="https://contabo.com/en/legal/terms-and-conditions/">Contabo terms of service.</a>
@ -27,11 +27,7 @@
Do not impersonate or otherwise deceptively claim yourself as a UNIX.dog admin.
All official communications will be from alpha at unix dot dog or this website.
</li>
<li>
Do not collect UNIX.dog user data without express
permission from the administrators or the user in
question.
</li>
<li>Do not collect UNIX.dog user data without express permission.</li>
<li>Do not use UNIX.dog services for commercial reasons.</li>
<li>Do not attack, compromise, or disrupt UNIX.dog services with malicious intent.</li>
<li>Be courteous of the shared resources provided, and be mindful of your time using them.</li>
@ -89,7 +85,7 @@
No "ex post facto" judgements.
</li>
<li>
Burden of proof is laid on the accuser, not the accused. Please keep this in mind
Burden of proof is laid on the accuser, not the accusee. Please keep this in mind
when submitting reports.
</li>
</ol>
@ -105,267 +101,19 @@
WITH THESE SERVICES OR THE USE OR OTHER DEALINGS IN THESE SERVICES.
</p>
</section>
<section>
<h2>Logging Disclaimer</h2>
<p>
The following information is collected by the services running on UNIX.dog.
</p>
<ul>
<li>Any content uploaded by users.</li>
</ul>
<h3>Akkoma</h3>
<p>
</p>
</section>
<small>These rules inspired by <a href="https://www.nuegia.net/services_draft.xhtml">Nuegia's TOS</a></small>
<section>
<h2>Data &amp; Logging Disclaimers</h2>
<p>
This section should be taken as a rough overview and guide as
to what happens to your data. UNIX.dog does not use your
data in any commercial capacity, and only stores data
necessary for service operation or security and auditing.
</p>
<p>
Much of the data is stored unencrypted due to the nature of
the services provided. Remember that while there are access
controls, the best way to safeguard your data is to encrypt
it yourself.
</p>
<p>
If you are concerned or believe that there is something
missing here, please reach out via email or XMPP.
</p>
<h3>
Data Accessible to the World
</h3>
<p>
The following data is publicly accessible by anyone with an
internet connection.
</p>
<h4>LDAP</h4>
<ul>
<li>Chosen username.</li>
<li>Personal information given on the account page.</li>
<li>SSH public keys.</li>
<li>Login shell.</li>
</ul>
<h4>XMPP</h4>
<p>Privacy settings can be configured with supported XMPP
clients.</p>
<ul>
<li>Personal information published on your VCARD.</li>
<li>Uploaded avatar image.</li>
<li>Presence information to your subscribed contacts.</li>
<li>
Other information exposed by your XMPP client. This can
include hostname and OS version. Check your XMPP client
for details.
</li>
</ul>
<h4>Mumble</h4>
<ul>
<li>Chosen username.</li>
<li>User channel info, if created.</li>
</ul>
<h4>E-Mail</h4>
<p>
Filters are not applied to outgoing mail. The following may
be included in the e-mail headers:
</p>
<ul>
<li>
Sender IP.
</li>
<li>Sender hostname.</li>
<li>Sender client identification string.</li>
</ul>
<h4>Akkoma</h4>
<p>Akkoma has built-in privacy settings.</p>
<ul>
<li>
Provided personal information such as display name,
bio, and profile
avatar.
</li>
<li>Posts and boosts marked as public.</li>
<li>
Your social network, i.e. your followers and who you are
following.
</li>
</ul>
<h4>IPFS</h4>
<p>
Due to the nature of IPFS, uploaded data can be accessed by
anyone with the CID.
</p>
<h4>Nextcloud</h4>
<p>Nextcloud has built in privacy settings.</p>
<ul>
<li>
Personal information published on your profile such as
display name, bio, profile avatar, and more.
</li>
<li>Files shared publicly.</li>
</ul>
<h4>Shell access</h4>
<p>
Files located under ~/public are accessible to the world, as
determined by their UNIX permissions.
</p>
<h3>
Data Accessible to UNIX.dog Users
</h3>
<p>
The following data can be accessed by people with a
registered UNIX.dog account.
</p>
<h4>Shell access</h4>
<ul>
<li>Last login times and IP, via WTMP logs.</li>
<li>
Currently open sessions and connection IP, via UTMP
logs.
</li>
<li>
The home directory has default permissions that let
others view the list of files, required for the public
folder to work. If this bothers you, consider changing
your umask in your shell RC file and storing files in a
subfolder.
</li>
<li>
Users can send you messages via the write and wall
commands. Use mesg n to disable.
</li>
</ul>
<h3>
Data Accessible to Administrators
</h3>
<p>
The following data is stored on the server, and is thus
accessible by administrators.
</p>
<h4>HTTP</h4>
<ul>
<li>
Access logs, which include source IP, request headers,
request path, and time.
</li>
<li>
Request data (i.e. POST or form data) is not
logged.
</li>
</ul>
<h4>LDAP</h4>
<ul>
<li>Password hashed with Argon2ID.</li>
</ul>
<h4>Akkoma</h4>
<p>
ActivityPub is not a secure protocol, and
should not be used for sensitive communications. Post
content can be deleted if needed, but posts could still
exist on other servers because of the nature of federation.
</p>
<ul>
<li>
Post and DM content, regardless of post visibility
setting.
</li>
<li>Error logs.</li>
</ul>
<h4>XMPP</h4>
<p>
If you use OMEMO encryption, message content is encrypted.
XMPP is also a federated protocol, so your data may be exposed
and stored on the server of the contacts you communicate with.
</p>
<ul>
<li>Your XMPP roster.</li>
<li>Uploaded files, published at an obfuscated URL.</li>
<li>
Message content, cached for 7 days in MAM, for both
private messages and group chats (MUCs).
</li>
<li>
Connection and authentication logs, which
includes connection IP.
</li>
</ul>
<h4>Legacy service XMPP bridges</h4>
<p>
The legacy service XMPP bridges are hosted on a seperate
server, not woofer.
</p>
<ul>
<li>
Provided credentials to authorize to the legacy service,
unencrypted.
</li>
<li>
Legacy contacts, synced to the UNIX.dog XMPP server.
</li>
<li>
Messages are stored unencrypted on the XMPP
server, and are thus also cached in MAM for 7 days.
</li>
</ul>
<h4>Forgejo</h4>
<ul>
<li>Any uploaded repositories.</li>
<li>Error logs.</li>
</ul>
<h4>E-Mail</h4>
<p>
E-Mail is an unencrypted protocol. Consider using PGP or
other encryption if you require secure communications.
</p>
<ul>
<li>E-Mail content in your home directory.</li>
<li>Authentication logs, including connection IP.</li>
<li>Transport logs, including source and destination address.</li>
<li>Error logs.</li>
</ul>
<h4>Nextcloud</h4>
<ul>
<li>File content.</li>
<li>Contacts and Calendar content.</li>
<li>Other data which is uploaded to the Nextcloud server.</li>
<li>Error logs.</li>
</ul>
<h4>Mumble</h4>
<ul>
<li>Client certificate public key, for authorization.</li>
<li>
Authentication logs, which include connection IP and
possibly client OS.
</li>
<li>Error logs.</li>
</ul>
<h4>SSH</h4>
<ul>
<li>
Authentication logs, which include connection IP,
username, and public key (if provided).
</li>
</ul>
<h4>IPFS Upload Service</h4>
<ul>
<li>Pinned CIDs, associated with a user.</li>
</ul>
</section>
</article>

View File

@ -27,10 +27,35 @@
3072 SHA256:1BH7BPNlROWxh+4/LttipJQFLps+J51IHRn+f6j+tVI root@woofer (RSA)
</pre>
</section>
<h1>Social</h1>
<section>
<h2>XMPP Messaging</h2>
<h2>File sync (Nextcloud)</h2>
<p>
Nextcloud is a FOSS, federating cloud drive platform with support
for messaging, web calendar and contacts management, and more.
It is available at <a href="https://cloud.unix.dog/">cloud.unix.dog</a>,
and you can log in with your UNIX.dog account for 10GB of storage :3
</p>
</section>
<section>
<h2>Social (Akkoma)</h2>
<p>
Akkoma is a federated social media platform, forked from Pleroma.
It can communicate with other instances running Mastodon, Misskey,
Friendica, and more.
Check it out at <a href="https://akko.unix.dog">akko.unix.dog</a>.
</p>
</section>
<section>
<h2>File upload (IPFS Pinning)</h2>
<p>
A custom-built IPFS remote pinning service is available at UNIX.dog.
It's hosted at <a href="https://u.unix.dog">u.unix.dog</a>.
Also, it works as a simple cURL or online file uploader; you don't
need to use a local IPFS node :3
</p>
</section>
<section>
<h2>Messaging (XMPP)</h2>
<p>
XMPP is a federated IM protocol. UNIX.dog uses ejabberd, and you can
connect to it using a client of your choice. A web client is also
@ -40,22 +65,10 @@
the UNIX.dog main chatroom. Your JID should be username@unix.dog.
</p>
</section>
<section>
<h2>Legacy Network Bridges</h2>
<p>
Some custom bridges are also available for use, including a
Matrix Bifrost bridge and an IRC Biboumi bridge, both
accessible from XMPP.
</p>
<p>
More information can be found on <a
href="/services/bridges">the bridges page.</a>
</p>
</section>
<section>
<h2>Mumble VoIP</h2>
<h2>Voice chat (Mumble)</h2>
<p>
Mumble is a free VoIP software that you can download from <a href="https://www.mumble.info/">mumble.info.</a>
Mumble is a free VOIP software that you can download from <a href="https://www.mumble.info/">mumble.info.</a>
You can join at <a href="mumble://chat.unix.dog/Hangout?title=UNIX.dog&version=1.2.0">chat.unix.dog.</a>
Users can create their own non-persistent channel, but if
you'd like a persistent channel for your group, just reach
@ -65,8 +78,7 @@
<section>
<h2>EMail</h2>
<p>
The future of messaging is here! Electronic mail services
are provided.
The future of messaging is here! Electronic mail is also provided.
You can connect any standard email client to smtp.unix.dog and
imap.unix.dog using your credentials
to access your inbox. The server also provides sendmail over SSH,
@ -77,38 +89,7 @@
</p>
</section>
<section>
<h2>Akkoma (ActivityPub)</h2>
<p>
Akkoma is a federated social media platform, forked from Pleroma.
It can communicate with other instances running Mastodon, Misskey,
Friendica, and more.
Check it out at <a href="https://akko.unix.dog">akko.unix.dog</a>.
</p>
</section>
<h1>Files and Productivity</h1>
<section>
<h2>IPFS Upload &amp; Pinning</h2>
<p>
A custom-built IPFS remote pinning service is available at UNIX.dog.
It's hosted at <a href="https://u.unix.dog">u.unix.dog</a>.
Also, it works as a simple cURL or online file uploader; you don't
need to use a local IPFS node :3
</p>
</section>
<section>
<h2>Nextcloud</h2>
<p>
Nextcloud is a FOSS, federating cloud drive platform with support
for messaging, web calendar and contacts management, and more.
It is available at <a href="https://cloud.unix.dog/">cloud.unix.dog</a>,
and you can log in with your UNIX.dog account for 10GB of storage :3
</p>
</section>
<h1>Hosting</h1>
<section>
<h2>Forgejo Git Hosting</h2>
<h2>Git hosting (Forgejo)</h2>
<p>
Forgejo is a simple git host. It is hosted at
<a href="https://git.unix.dog">git.unix.dog</a> and should
@ -119,40 +100,18 @@
</p>
</section>
<section>
<h2>Static Webhosting</h2>
<h2>Static webhosting</h2>
<p>
Files under ~/public are hosted at unix.dog/~username. A list
of user websites can be found <a href="/users">here.</a>
</p>
</section>
<section>
<h2>Gemini Hosting</h2>
<h2>Gemini hosting</h2>
<p>
You can also host gemini pages under ~/public/gemini. UNIX.dog runs
the Molly-Brown server, so all pages are hosted under unix.dog/~username
as well. :3
</p>
</section>
<h1>Networks</h1>
<section>
<h2>Yggdrasil Node</h2>
<p>
The server is also a part of the <a
href="https://yggdrasil-network.github.io/">Yggdrasil
network,</a> which provides a layered mesh routing scheme
based on IPv6 addresses that encode public keys.
</p>
<p>
You're free to use Yggdrasil to access any of these services
(some might not work correctly without configuration), or
even peer with the server for access to the network.
</p>
<p>
Here are the connection details:
</p>
<pre>quic://woofer.unix.dog:1885
tcp://woofer.unix.dog:1886
tls://woofer.unix.dog:1887</pre>
</section>
</article>

View File

@ -8,11 +8,4 @@
<a href="/vnstat-5m.txt"><img class="stats" alt="Network usage in 5m intervals" src="/vnstat-5m.png"></a>
<a href="/vmstat-cpu.txt"><img class="stats" alt="CPU usage graph" src="/vmstat-cpu.png"></a>
<a href="/vmstat-mem.txt"><img class="stats" alt="Memory usage graph" src="/vmstat-mem.png"></a>
<img class="stats" alt="Traffic in graph" src="/net-in.png">
<noscript>If you'd like, there's also an interactive JavaScript
chart that uses Plotly. Network traffic is hard to see well in such
a small graph!</noscript>
<script src="/js/plotly-basic-2.27.1.min.js"></script>
<div class="stats" style="height: 400px;" id="net-stats"></div>
<script src="/js/net-plot.js"></script>
</article>

View File

@ -8,7 +8,7 @@
<li>
~<%= $user->{username} %>
% if ($user->{has_web_page}) {
<a href="/~<%=$user->{username}%>/">web</a>
<a href="https://unix.dog/~<%=$user->{username}%>/">web</a>
% }
% if ($user->{has_gem_page}) {
<a href="gemini://unix.dog/~<%=$user->{username}%>/">gemini</a>

View File

@ -1,114 +0,0 @@
% title 'UNIX.dog Services';
% layout 'default';
<article>
<h1>Legacy Service Bridging</h1>
<p>
UNIX.dog runs a few bridges to other services, documented on
this page.
</p>
<section>
<h2>Matrix Bifrost</h2>
<p>
The ARIA-net fork of Bifrost is set up to provide access to
XMPP MUCs and Matrix rooms to users of both services. Use
the <a href="#bridgehelper">bridge helper</a> below to
quickly get the correct address.
</p>
<p>
The Bifrost instance on UNIX.dog is set up as follows:
</p>
<p>
From XMPP, use #roomname#domain@matrix.unix.dog for rooms
and username_host@matrix.unix.dog for users.
</p>
<p>
From Matrix, use @_xmpp_user=40domain:unix.dog for users and
#_xmpp_roomname_domain:unix.dog for MUCs.
</p>
</section>
<section>
<h2>Biboumi IRC Bridge</h2>
<p>
Biboumi provides access to IRC networks from XMPP. The
component domain is biboumi.unix.dog.
</p>
<p>
You can connect to IRC channels using the syntax
#roomname%domain@biboumi.unix.dog.
</p>
</section>
<section id="bridgehelper">
<h2>XMPP and Matrix Bridge Helper</h2>
<p id="result">
</p>
<noscript>Since JS is disabled, this form will send the addresses to
the UNIX.dog server to convert.</noscript>
<form id="bridging" method="post">
<div>
<label for="bridge_service">Bridge:</label>
<select name="bridge" id="bridge_service">
<option value="unix.dog">UNIX.dog</option>
<option value="aria-net">ARIA-net</option>
</select>
</div>
<div>
<select name="type" id="bridge_type">
<option value="muc">XMPP MUC:</option>
<option value="room">Matrix Room:</option>
<option value="jid">XMPP User:</option>
<option value="user">Matrix User:</option>
</select>
<input type="text" id="handle" name="handle" required />
</div>
<div>
<input type="submit"/>
</div>
</form>
</section>
<script>
const conversion = {
"unix.dog": {
"muc": jid => (s => `#_xmpp_${s[0]}_${s[1]}:unix.dog`)(jid.split("@")),
"room": rm => `${rm.replace(":","#")}@matrix.unix.dog`,
"jid": jid => `@_xmpp_${jid.replace("@", "=40")}:unix.dog`,
"user": u => `${u.slice(1).replace(":","_")}@matrix.unix.dog`
},
"aria-net": {
"muc": jid => (s => `#_bifrost_${s[0]}_${s[1]}:aria-net.org`)(jid.split("@")),
"room": rm => `${rm.replace(":","#")}@aria-net.org`,
"jid": jid => `@_bifrost_${jid.replace("@", "=40")}:aria-net.org`,
"user": u => `${u.slice(1).replace(":", "_")}@aria-net.org`
},
};
const urlify = {
"room": jid => `xmpp:${encodeURI(jid)}?join`,
"muc": room => `https://matrix.to/#/%23${encodeURI(room.slice(1))}`,
"user": jid => `xmpp:${encodeURI(jid)}?roster`,
"jid": u => `https://matrix.to/#/${encodeURI(u)}`,
};
const form = document.getElementById("bridging");
const output = document.getElementById("result");
form.addEventListener("submit", e => {
e.preventDefault();
const formData = new FormData(form);
let service = formData.get("bridge");
let type = formData.get("type");
let handle = formData.get("handle");
let bridged = conversion[service][type](handle);
output.textContent = `Use address `
let link = document.createElement("a");
link.href = urlify[type](bridged);
link.textContent = bridged;
output.appendChild(link);
});
</script>
</article>