Skip to content

Instantly share code, notes, and snippets.

@mbican
mbican / bw_export_kp.py
Created November 4, 2023 12:04 — forked from mohamedadaly/bw_export_kp.py
Export Bitwarden to KeePass 2 XML format
#!/usr/bin/python
from __future__ import print_function
import base64
import commands
import json
import sys
import uuid
import xmltodict
@mbican
mbican / DS-HOTP-QR-generator.htm
Created April 29, 2019 09:26 — forked from mormegil-cz/DS-HOTP-QR-generator.htm
Generátor QR kódu pro inicializaci HOTP pro datové schránky
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<title>Generátor QR kódu pro inicializaci HOTP pro datové schránky</title>
<meta name="copyright" content="Bedřich Košata, Laboratoře CZ.NIC" />
<meta name="original-source" content="http://blog.nic.cz/2011/10/10/kouzlo-standardizovaneho-reseni/" />
</head>
<body>
<h1>Generátor QR kódu pro inicializaci HOTP pro datové schránky</h1>
0xa852Dc0D236C26E5aE431838B6D6ae9639e437d4
pragma solidity ^0.4.8;
contract tokenRecipient { function receiveApproval(address _from, uint256 _value, address _token, bytes _extraData); }
contract MyToken {
/* Public variables of the token */
string public standard = 'Token 0.1';
string public name;
string public symbol;
uint8 public decimals;
uint256 public totalSupply;
pragma solidity ^0.4.2;
contract owned {
address public owner;
function owned() {
owner = msg.sender;
}
modifier onlyOwner {
if (msg.sender != owner) throw;
@mbican
mbican / Liberal Regex Pattern for All URLs
Last active August 29, 2015 14:05 — forked from gruber/Liberal Regex Pattern for All URLs
Liberal Regex Pattern for quick matching strings which might be URLs
Quickly matches strings which might be URLs
matches all valid IRI (URL) with slash (e.g. schema:/path but not
schema:path) because matching schema:path would cause to many false
positives.
Not all matched strings are valid URIs.
It also matches these strings:
www.example.com or ftp.example.com or example.com/q
they require to manually add prefix http:// or ftp://