Skip to content

Instantly share code, notes, and snippets.

HIP-000? : Handshake SLDs

Number:  HIP-000?
Title:   Handshake SLDs
Type:    Standards
Status:  Pre-draft
Authors: Vlad Smirnov <http://smirnov/>
Created: 2021-07-30
@vladiuz1
vladiuz1 / antifish.md
Last active October 21, 2020 12:51
antifishing backgrounds

cookie-based backgrounds

In order to avoid fishing, every user's login prompt on a website should have unique background.

These backgounds will be generated similarly to one of these websites:

Both websites, use somekind of algorithm that converts data into background image.

@vladiuz1
vladiuz1 / swap-online-clipboard.md
Last active August 19, 2018 09:11
swap.online js experiments

A. User login process.

  1. User visits a website, and on every visit she/he is issued a unique session cookie (authToken).
  2. User enters email and password.
  3. A pbkdf2 key is generated using a formula privateKey = pbkdf2(concat(email, password)).
  4. authToken, ipAddress concatenation is signed by JavaScript ecdsa library with the resulting privateKey, and sent to server to authorize the token to access account.
  5. Server checks the signature against publicKey stored in database (publicKey is in turn signed by email server during email verification step when signing up or changing password and this sig is also checked). Among other things, the server checks if the token corresponds to IP address it was generated for, and the time it was generated for has not expired.
  6. If everything is ok, the authToken is authorized to log the user in - i.e. saved in local db along with important info. And during the login session this authToken is always passed to server and checked against db.
### Keybase proof
I hereby claim:
* I am vladiuz1 on github.
* I am vladiuz (https://keybase.io/vladiuz) on keybase.
* I have a public key ASBkgARaMV47X2TyubGfgYexB3OZMcgZNcirimplRUIdiAo
To claim this, I am signing this object:
class account_object : public graphene::db::abstract_object<account_object>
{
public:
account_object(); ///< constructs empty / null address
explicit account_object( const std::string& base58str ); ///< converts to binary, validates checksum
account_object( const fc::ecc::public_key& pub ); ///< converts to binary
explicit account_object( const fc::ecc::public_key_data& pub ); ///< converts to binary
account_object( const pts_address& pub ); ///< converts to binary
account_object( const public_key_type& pubkey );
//
// paste below code here:
// https://p5js.org/examples/math-distance-2d.html
// for a nice array.io affect.
//
var max_distance;
var mouseover = false;
var cell_size = 15;
var canvW = 710;
// reworked example available here:
// https://p5js.org/examples/math-distance-2d.html
//
var max_distance;
var mouseover = false;
var cell_size = 15;
var canvW = 710;
var canvH = 400;
var d = new Array();
// https://p5js.org/examples/math-distance-2d.html
var max_distance;
var mouseover = false;
var cell_size = 15;
var canvW = 710;
var canvH = 400;
var d = new Array();
function setup() {
// go here:
// https://p5js.org/examples/math-distance-2d.html
// and copy pase code below:
// ------------------ START ---------------------------
var max_distance;
var mouseover = false;
var cell_size = 15;
var canvW = 710;
var canvH = 400;