From afb5cd9e3ce3c718da58fb5e42013cc306236ddd Mon Sep 17 00:00:00 2001 From: pluja Date: Sat, 22 Jun 2024 13:17:07 +0200 Subject: [PATCH] add silent payments support --- src/config/config.go | 7 +- src/frontend/templates/about.html | 334 +++++++++++++----------------- src/main.go | 1 + src/server/web_handlers.go | 11 +- 4 files changed, 154 insertions(+), 199 deletions(-) diff --git a/src/config/config.go b/src/config/config.go index 5ee6bb5..525612e 100644 --- a/src/config/config.go +++ b/src/config/config.go @@ -10,9 +10,10 @@ type Config struct { } type Donations struct { - Xmr string - Btc string - Lnn string + Xmr string + Btc string + BtcSilent string + Lnn string } var Conf Config diff --git a/src/frontend/templates/about.html b/src/frontend/templates/about.html index 3c14982..76cf964 100644 --- a/src/frontend/templates/about.html +++ b/src/frontend/templates/about.html @@ -78,11 +78,9 @@ } -
-
-
+
+
+
Why · What @@ -128,8 +126,10 @@

- With KYCNOT.ME, I hope to provide people with trustworthy alternatives for buying, exchanging, trading, and using cryptocurrencies - without having to disclose their identity, thus preserving the right to privacy. I want to help preserve the original + With KYCNOT.ME, I hope to provide people with trustworthy alternatives for buying, exchanging, trading, and + using cryptocurrencies + without having to disclose their identity, thus preserving the right to privacy. I want to help preserve the + original ethos of cryptocurrencies.

@@ -150,28 +150,24 @@ criminals know perfectly how to avoid such policies. In fact, they normally use the FIAT system and don't even need to use cryptocurrencies. Banks are the biggest money launders, the - HSBC scandal, - Nordea + HSBC + scandal, + Nordea or - Swedbank + Swedbank are just some examples.

- Chainalysis found that only 0.34% of the transaction volume with cryptocurrencies in 2023 was attributable to criminal - activity. Bitcoin's share of this is significantly lower with 25%. Illicit transactions with Euros accounted for 1% of - the EU's GDP or €110 billion in 2010. [1] [2] + Chainalysis found that only 0.34% of the transaction volume with cryptocurrencies in 2023 was attributable to + criminal + activity. Bitcoin's share of this is significantly lower with 25%. Illicit transactions with Euros accounted + for 1% of + the EU's GDP or €110 billion in 2010. [1] [2]

KYC only affects small individuals like you and me. It is an annoying @@ -194,7 +190,7 @@

why only Bitcoin and Monero?

Bitcoin: it's the initial spark of the decentralized money. - A solid project with a strong community. It is the most well-known and widespread cryptocurrency. + A solid project with a strong community. It is the most well-known and widespread cryptocurrency.

Monero: if digital cash was to exist, it should be like @@ -212,7 +208,8 @@

request

You can request a new listing by visiting the - Request page. The request form requires javascript to avoid spam. Read more about the PoW captcha in this section.. + Request page. The request form requires javascript to avoid spam. Read more about the PoW captcha in this section..

listing process

@@ -288,10 +285,14 @@ still get a high score.

-

The scoring algorithm is open source, - pull requests to improve it are welcome. - It runs once every hour, meaning scores cannot be manually modified since they will be recalculated by the algorithm hourly. You can visit - a service's score breakdown to see how it is calculated.

+

The scoring algorithm is open source, + pull requests to improve it are welcome. + It runs once every hour, meaning scores cannot be manually modified since they will be recalculated by the + algorithm hourly. You can visit + a service's score breakdown to see how it is + calculated. +

order

@@ -341,7 +342,9 @@

terms of service auto-reviews

- KYCnot.me features an AI-powered tool that automatically reviews Terms of Service (ToS) for all the different services. It breaks down the ToS content, highlights the main points, and translates them into easy-to-understand language, aiming to simplify the comprehension of any service's ToS. + KYCnot.me features an AI-powered tool that automatically reviews Terms of Service (ToS) for all the different + services. It breaks down the ToS content, highlights the main points, and translates them into + easy-to-understand language, aiming to simplify the comprehension of any service's ToS.

@@ -350,7 +353,8 @@

- Important note: The automated tool generally delivers reliable and solid results. But it might flag false positives or irrelevant lines, if you find something's off, please contact me. + Important note: The automated tool generally delivers reliable and solid results. But it might flag false + positives or irrelevant lines, if you find something's off, please contact me.

@@ -359,69 +363,42 @@

If you like this project, or - any of my other projects, you can support me through these methods: + any of my other projects, you can support me through these + methods:

- + + stroke-width="0" fill="currentColor" /> Monero

> If your wallet supports - OpenAlias, you can use kycnot.me in the + OpenAlias, you can use kycnot.me in the address field.

{{.Xmr}}
- + - + - + - + @@ -432,11 +409,8 @@ Click for QR Code - Monero address QR code + Monero address QR code
@@ -444,24 +418,13 @@ - + + stroke-width="0" fill="currentColor" /> Bitcoin @@ -469,30 +432,15 @@
- + - + - + - + @@ -503,47 +451,65 @@ Click for QR Code - Bitcoin Address QR Code + Bitcoin Address QR Code +
+
+ + + + + + + + + + + + + + Bitcoin silent + payments + + {{.BtcSilent}} + +
+ + + + + + + + + + + + + + + + + Click for QR Code + + Bitcoin Address QR Code
- + - Tip via Lightning Network - - - - - Paynym + Tip via Lightning Network
@@ -553,33 +519,25 @@

contact

Due to past misuse and difficulties in managing, I've decided to remove direct instant - messaging/email contacts. If you have any queries or concerns, connect with me on any of the listed social media platforms below. + messaging/email contacts. If you have any queries or concerns, connect with me on any of the listed social media + platforms below.

- For confidential communication, please reach out via the specified platforms and I can provide my email, matrix, xmpp, threema or a SimpleX link. + For confidential communication, please reach out via the specified platforms and I can provide my email, matrix, + xmpp, threema or a SimpleX link.

@@ -589,19 +547,24 @@

Each service has a dedicated comments section. The comments are suppored - by Matrix, an open network for secure, - decentralised communication, thanks to Cactus. + by Matrix, an open network for secure, + decentralised communication, thanks to Cactus.

- To comment on a service's page, you just need a Matrix account. This method gives users full control over who hosts their data. Users can log in using any Matrix server they choose. + To comment on a service's page, you just need a Matrix account. This method gives users full control over who hosts + their data. Users can log in using any Matrix server they choose.

- You can read and post comments in your browser, or continue the conversation using any other Matrix client. Comment sections are accesible from any homeserver on the Matrix network. + You can read and post comments in your browser, or continue the conversation using any other Matrix client. + Comment sections are accesible from any homeserver on the Matrix network.

-

The source code for the web client is LGPLv3 licensed, and the backend service is AGPLv3 licensed.

+

The source code for the web + client is LGPLv3 licensed, and the backend service is AGPLv3 licensed.

@@ -637,7 +600,7 @@

KYCNOT.me does not have trackers and never will. It does not make any third party connections from the frontend. No user data of any kind is - collected. A "no-referrer" policy is enforced. Tor and I2P sites are available + collected. A "no-referrer" policy is enforced. Tor and I2P sites are available (check the footer).

@@ -652,7 +615,9 @@
Service Requests: The Proof-Of-Work captcha, that I coded myself, needs - JavaScript for the verfication. It is an open-source 2.5kb javascript function. + JavaScript for the verfication. It is an open-source + 2.5kb javascript function. Comments: The comment section on each of the services, needs @@ -678,9 +643,7 @@

example 2: - /api/v1/service/localmonero.co + /api/v1/service/localmonero.co

@@ -698,25 +661,14 @@ is the referral, if there is any. But there's always a referral-free option, that is shown with a - + - + icon. Feel free to choose.

@@ -734,4 +686,4 @@

-
+
\ No newline at end of file diff --git a/src/main.go b/src/main.go index cdd499a..2fab47c 100644 --- a/src/main.go +++ b/src/main.go @@ -61,6 +61,7 @@ func init() { // Load donation addresses into config config.Conf.Donations.Xmr = os.Getenv("XMR_ADDRESS") config.Conf.Donations.Btc = os.Getenv("BTC_ADDRESS") + config.Conf.Donations.BtcSilent = os.Getenv("SLIENT_ADDRESS") config.Conf.Donations.Lnn = os.Getenv("LNN_ADDRESS") // Database init diff --git a/src/server/web_handlers.go b/src/server/web_handlers.go index 54b54a0..872bde3 100644 --- a/src/server/web_handlers.go +++ b/src/server/web_handlers.go @@ -211,11 +211,12 @@ func (s *Server) handleRequestServiceForm(c iris.Context) { func (s *Server) handleAbout(c iris.Context) { c.ViewLayout("main") data := iris.Map{ - "Title": "About", - "Current": "about", - "Btc": config.Conf.Donations.Btc, - "Xmr": config.Conf.Donations.Xmr, - "Lnn": config.Conf.Donations.Lnn, + "Title": "About", + "Current": "about", + "Btc": config.Conf.Donations.Btc, + "Xmr": config.Conf.Donations.Xmr, + "BtcSilent": config.Conf.Donations.BtcSilent, + "Lnn": config.Conf.Donations.Lnn, } if err := c.View("about", data); err != nil { c.HTML("

%s

", err.Error())