Skip to content

Instantly share code, notes, and snippets.

View AvinashSKaranth's full-sized avatar

Avinash S Karanth AvinashSKaranth

View GitHub Profile
@AvinashSKaranth
AvinashSKaranth / client.js
Last active October 6, 2022 07:58
JWT Security for Offline Token Generation and Validation
// Client side Offline Token Generation
require("dotenv").config();
const http = require("http");
const jwt = require("jsonwebtoken");
const token = jwt.sign({ method: "send" }, process.env.CLIENT_SECRET, {
algorithm: "HS256",
header: { typ: "JWT", kid: process.env.CLIENT_ID },
});
const postData = JSON.stringify({
somedata: "123",
@AvinashSKaranth
AvinashSKaranth / bootstrap-basic-template.htm
Created April 20, 2016 18:15 — forked from justincarroll/bootstrap-basic-template.htm
This is my personal Bootstrap 3 and Font Awesome 4 basic HTML template.
<!DOCTYPE HTML>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Bootstrap Basic Template</title>
<link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
<link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css">
<link rel="stylesheet" href="style.css">