I hereby claim:
- I am leonletto on github.
- I am leonletto (https://keybase.io/leonletto) on keybase.
- I have a public key whose fingerprint is 5B6A CBD5 95EB 08C8 0962 8771 3CAB DA24 75AC 8597
To claim this, I am signing this object:
### Basic webserver to check ports are available | |
## | |
## copy into a directory - for example c:\test | |
## open a command prompt and cd into that directory | |
## run 'powershell' - enter | |
## | |
## the first time you run powershell you will need to allow scripts to run | |
## to do this type 'Set-ExecutionPolicy UnRestricted' - enter | |
## | |
## Now type '.\powershell-web-server.ps1 2010' - enter |
I hereby claim:
To claim this, I am signing this object:
// Load the TCP Library | |
net = require('net'); | |
// Keep track of the chat clients | |
var clients = []; | |
// Start a TCP Server | |
net.createServer(function (socket) { | |
// Identify this client |
TLDR: JWTs should not be used for keeping your user logged in. They are not designed for this purpose, they are not secure, and there is a much better tool which is designed for it: regular cookie sessions.
If you've got a bit of time to watch a presentation on it, I highly recommend this talk: https://www.youtube.com/watch?v=pYeekwv3vC4 (Note that other topics are largely skimmed over, such as CSRF protection. You should learn about other topics from other sources. Also note that "valid" usecases for JWTs at the end of the video can also be easily handled by other, better, and more secure tools. Specifically, PASETO.)
A related topic: Don't use localStorage (or sessionStorage) for authentication credentials, including JWT tokens: https://www.rdegges.com/2018/please-stop-using-local-storage/
The reason to avoid JWTs comes down to a couple different points:
urlencode() { | |
# urlencode <string> | |
old_lc_collate=$LC_COLLATE | |
LC_COLLATE=C | |
local length="${#1}" | |
for (( i = 0; i < length; i++ )); do | |
local c="${1:$i:1}" | |
case $c in |
# sources:
# https://kb.op5.com/pages/viewpage.action?pageId=19073746#sthash.9gTMRKM1.dpbs
# https://stackoverflow.com/a/26093147
# https://jamielinux.com/docs/openssl-certificate-authority/sign-server-and-client-certificates.html
# additional ressource: https://gist.github.com/Soarez/9688998
# TODO: renew certificates and ca, add capability for authentication to client cert
# TODO ressources: https://gist.github.com/richieforeman/3166387
HKP_PATH=""
Wait, what?
Inspired by this awesome article.
According to wikipedia, OOP is a programming paradigm or technique based on the concept of "objects". The object structure contain data and behaviour.
Data is the object's state, which should be isolated and must be private.
Being able to SSH directly into a compute job has the advantage of using all remote development tools such as using your IDE's debugger also for GPU jobs (VSCode, PyCharm, ...).
General problem: