Skip to content

Instantly share code, notes, and snippets.

View pikami's full-sized avatar
Coffee is awesome

Pijus Kamandulis pikami

Coffee is awesome
View GitHub Profile
package main
import (
"context"
"encoding/json"
"fmt"
"io/ioutil"
"log"
"net/http"
"strconv"

Server setup

  1. Add these lines to /etc/tor/torrc
HiddenServiceDir /var/lib/tor/ssh_hidden_service/
HiddenServicePort 22 127.0.0.1:22
HiddenServiceAuthorizeClient stealth client_name
  1. Restart tor service
  2. Get onion address and client key from /var/lib/tor/ssh_hidden_service/hostname
@pikami
pikami / NimsesApi.md
Created June 9, 2019 15:25
Nimses API

Nimses API

Headers to send:

"content-Type": "application/json"

Feed

Get posts made by user

  • URL: /api/feed/user
  • METHOD: GET
try_files $uri /index.php;
location ~ \.php$ {
fastcgi_pass 127.0.0.1:9000;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
it tries to load the uri first, if it can't it uses index.php instead

Keybase proof

I hereby claim:

  • I am pikami on github.
  • I am pikami (https://keybase.io/pikami) on keybase.
  • I have a public key whose fingerprint is CF1F 0187 1BE3 5E40 4F8A 8B91 BC76 B6AE 1621 35E6

To claim this, I am signing this object: