Skip to content

Instantly share code, notes, and snippets.

View cisiqo's full-sized avatar
🫑
Looking for a job

chengshq cisiqo

🫑
Looking for a job
View GitHub Profile
-module(test).
-export([start/0, start1/0, start2/0]).
-include_lib("xmerl/include/xmerl.hrl").
make_doc_xml(Fields) ->
Xml = xmerl:export_simple([doc_xml_simple(Fields)], xmerl_xml,
[{prolog, ""}]),
unicode:characters_to_binary(Xml).
@cisiqo
cisiqo / unescape.php
Created November 15, 2018 04:01
php unescape
function unescape($str)
{
$ret = '';
$len = strlen($str);
for ($i = 0; $i < $len; $i ++)
{
if ($str[$i] == '%' && $str[$i + 1] == 'u')
{
$val = hexdec(substr($str, $i + 2, 4));
if ($val < 0x7f)
keytool -genkeypair -alias cas -keyalg RSA -keypass changeit -storepass changeit -keystore \path\to\thekeystore -dname "CN=cas.example.org,OU=Example,OU=Org,C=US" -ext SAN="dns:example.org,dns:localhost,ip:127.0.0.1"