3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $key="0123456789123456"; $iv = mcrypt_create_iv(16, MCRYPT_DEV_URANDOM); $plain = "id=0"; $res = mcrypt_encrypt(MCRYPT_RIJNDAEL_128, $key, $plain, "cbc", $iv); $res = base64_encode($iv.$res); print_r($res); /*$res = base64_decode($iv.$res); $iv = substr($res,0, 16); $res = substr($res, 16, strlen($res)-16); $res = mcrypt_decrypt(MCRYPT_RIJNDAEL_128, $key, $res, "cbc", $iv); $res = str_replace("\x00", "", $res); parse_str($res, $arr); var_dump($arr);*/
based on 3XcPt
Output for 7.0.6 - 7.2.0
Fatal error: Uncaught Error: Call to undefined function mcrypt_create_iv() in /in/4hrHU:3 Stack trace: #0 {main} thrown in /in/4hrHU on line 3
Process exited with code 255.
Output for 7.0.5
nzYk5xw9109eLpQN7r0Diy2EztW6EHcXD4fQZVvWgHo=
Output for 7.0.4
LCeC2CEhS4Ga1nXXsQqSpEl4oUuHn+Ia/AeGrY3rNJM=
Output for 7.0.3
36o+aOhMDUNlKubGQEuTle251s7X08uvMf7S8iZ3OGo=
Output for 7.0.2
7BXnmcu1xVw1YDgSo3iwMQZLcJZY1ekV4LH1OkRnGiA=
Output for 7.0.1
ANdorBSvyy+ypSdZrpOq+HBGch3w5y/Ip827HT4F6mA=
Output for 7.0.0
rPjyA04DcFyDJyreox5i+TQBsRrIBnEvwStApKOlIZg=
Output for 5.3.18 - 5.3.29, 5.5.35, 5.6.21 - 5.6.28
Fatal error: Call to undefined function mcrypt_create_iv() in /in/4hrHU on line 3
Process exited with code 255.
Output for 5.6.20
SM0iaaNAX2ofSSVKsFDTTFW4JqhuaihNLth6V/m95K4=
Output for 5.6.19
hN9BCHBRvF3p8fQdF73HRx0HgmW/ZHMAd48nr8dliZ0=
Output for 5.6.18
5vibNnEvZKSDzt40qv8CmPnEwOXDhxdo9DTCjty2w5k=
Output for 5.6.17
GvbUvnYlelvOYSPAuGqIiK4UmtxyS/fZT2uaz/ex99Q=
Output for 5.6.16
iBbbdoA/zSzUATveebryXz/eMr15zxyTl4GMveUuyFQ=
Output for 5.6.15
cs+qD3Uf5HDceDzEV2oI3ep3b9oeeR+S5lPLi3BQzVA=
Output for 5.6.14
yAKtRRszJuPG2JyS1tmYDOWlnNGdwag3SHPUSs43Q7I=
Output for 5.6.13
wc1y9dwlkBfPrN931ifIlAal+1cIaT1jTM04CYKt1No=
Output for 5.6.12
0zs40pTeqS1Mc7oVwDgXXQEfuyq+xg/alLonlLITzZ4=
Output for 5.6.11
n3jHLtXxl0zGenomom6PBCw7iA/CXpNpO2sTaMraHVE=
Output for 5.6.10
hAll2ktRH2ESfJnPBPMOMRCZ2UJrpYttRrYOsgEv2T0=
Output for 5.6.9
YM5KsdK/pXJLtsBq30q3FFJ/wVhc2fJxO8PcpfQFiQA=
Output for 5.6.8
LrYLnIjEJcRAaypRewRWvS59NPDbI3MKrndr/Fag3uA=
Output for 5.5.34
+Wmyjyn784dk5xWKrNndwpuTC7RfVkoj9NpDAMFht4g=
Output for 5.5.33
RaWmssNGjcYSGH/OQDBLtbS49qinBH+gDNXlb6I5HJQ=
Output for 5.5.32
5dpOc1TmZSZKSfDBb3WoSt2tcq9iM7zlvbtERECLMnY=
Output for 5.5.31
10gBn+LhfOv+pG8fW+Q60Yh1bj9XomsMkiS+xCIkYms=
Output for 5.5.30
OljhJlsfQzbIn46kqeLhtlN6aEBvpTiYhI4iCnZX2lY=
Output for 5.5.29
T1oDTLgkGXNh25hJZGw+bEnP7p6AjM+TCpddyegDHwQ=
Output for 5.5.28
nmEZqmfWuPXmJAEVozKrP16QX7jwtNx68Q+vdVh7y+c=
Output for 5.5.27
uYxI6gNze5hnYWQ1ZhwytSKJdpMCQklqdd/8TqoCwew=
Output for 5.5.26
/pgW8ZAY7h7B7ex6+wTGxoed6YAzhCJy99Mb6khZTTA=
Output for 5.5.25
brRneFlhSLsgwyGBGdU4yY40TvCTCGMTWadN/BwBSB8=
Output for 5.5.24
ejIp06tzgLsf+NvZFI3WRURNRAFP3e+EmNMgOHf4b9k=
Output for 5.4.45
oLv1uSghYdDiD3f/4xVAbB36UCWvkk2EH3a08ZbkxCw=
Output for 5.4.44
ZmEpNoAnZMYfQTaYK6urzYq0PpHhNswh/bD4gOV5pvc=
Output for 5.4.43
9CAxHnr1gmGp+ZNCj4PHwCG9kKq+mqmQvbodxJWaHBM=
Output for 5.4.42
qpJvBUr5RWnuS6HWSOjuAzHxAE5PCg+wzuc0gjav7cA=
Output for 5.4.41
Di5Kha0gfJa5PXC7oxCQSsYYEgwqHX66U18nREY4YQY=
Output for 5.4.40
PDD45F7UUfv4gcvCQcg/NWPHiRDxuruXu8M2Dr1DDyo=
Output for 5.4.39
BXuOrqCZkNDXGGkEA+/bGbWcUkzp49gS3PIvDKYSvGc=
Output for 5.4.38
y46pLIUdsZ+eVZ6hxLm+umn57dUVetR+by5hzkTxM4A=
Output for 5.4.37
jxO4J7sYY7jrGpnrOLeeUao3HcsffE7LNwlgvtiu/Ng=
Output for 5.4.36
HZ2zRReybtkoTO6+YFT2n5xOI415h69CoUOHi1j52rQ=
Output for 5.4.35
2Ie3Mf26bNJ2PmXZPcM5J1ATjjZDF/u6zM+2aKz7hig=
Output for 5.4.34
IobdiW7Rn2J5k+BGspTvJd+9qPllZSiqSY1SPQwPCW4=
Output for 5.4.32
fsd48zBiOXRhOPNCQ7iDd5B3TMcuL+7+KrLSAOFU9jg=
Output for 5.4.31
z4T1GBJriY/5QDfLt83xSux5u2oKEytvUT1cXpzwbHc=
Output for 5.4.30
9aH2WlWKAM9RRs/VEHHQZYadaTAi0BwQcwbRpML/U+o=
Output for 5.4.29
UnmLqWXvfQtLQQO8usAnE3URtpIm7AZMbvK1RPj16vI=
Output for 5.4.28
YDb/tQJy/00MZniLs/JcApG5o7oMEp+GjiQC2AcSnrM=
Output for 5.4.27
fK5XSgIBqHXNfeW9jZfn8MAeK9dyK9x0bjaqt6iz9w8=
Output for 5.4.26
SJxcNT4fgVkCJ8vEqzPob+wTxVBONWVyiMbllD71974=
Output for 5.4.25
QuXdk1TVbliwWO1wGBi/akLIRWo0s4Muet1zZhDWun4=
Output for 5.4.24
OmRAtlWfF1iun/XgPVW3CDB6LAYghR/RaaFzHoRdf8Q=
Output for 5.4.23
4///GTKCYvwF4vUyMFjXFz0wvBp1HTkya5UbFq50P1g=
Output for 5.4.22
wcZaJivhiFMQxfas6Uz2xcCySv2cM3vgflbTe+h2fTY=
Output for 5.4.21
Y8ZWQLfw30azHbxrCJ2S8NkLXSsZb3V6yf6YnWPhxEc=
Output for 5.4.20
nnHNf6AT7PAmzNIOYWubxtNrSpvcRcymonGF19JGSbA=
Output for 5.4.19
8KbRuCbWg4XikC3PbratwTWF0DfvdtC3tY6mI0nTnAA=
Output for 5.4.18
tit/ZN3LOFDVbbH8GhUs0F/TdMmAH7qAKDcV3PFr+0w=
Output for 5.4.17
/AgIDWKUGEX7OYiVqSVISxEtHp1ZhPrPSquABaz4Vdc=
Output for 5.4.16
zC8a+IFG2I8WHJiTMw1y5274RqZYSVXhmQHDtTv6CvY=
Output for 5.4.15
fIXCr73MmAU52WuvkMWAJDYBVPZiAkGAmqb9U803CIo=
Output for 5.4.14
83CK+b9kd+i8zP6WDinqbuf/QM6nYHSaij05QDffQ64=
Output for 5.4.13
OlpLcwyCJESoPAtpG48LZT6GNkn5+ki0EG8dpH0c2y0=
Output for 5.4.12
be5EIfxIBoDJWys3Ka56SiVGwp0zdWmj9RAKcczeYcY=
Output for 5.4.11
ZQQbISiHAsY2v8vi6lDJWXxO70F3OM8yWGxv5dvQg7M=
Output for 5.4.10
FUpkcsiFq1+hKsU5r0WKAn/QcY4MUNgKRGapIGS5L24=
Output for 5.4.9
uyFHzzbVrsS8I2YuXbNcUePYbg9m2Urk0uR0oETQjRo=
Output for 5.4.8
UUzqcE8Xle4QnsAAKfI4tk3zIAiOrn7EW7fSjs1JhKE=
Output for 5.4.7
LtyMqSP50jdAqU1nY3VEhGO1hiOmxiBKWDaW54aUAF4=
Output for 5.4.6
dSj735QseVRsA1olLrby1/aAgMQ3MYVH9BBwL/1NWYU=
Output for 5.4.5
0kKv81xajsaBQlW4ksi3f4yUI2ozxgXGpHdHLmjsSto=
Output for 5.4.4
5zS9WmakppGiIYeanYUAt2hovRq+F/zVz60EvNCCAbs=
Output for 5.4.3
ZiqO7iRfL/zrDLmvjb4Xhe0jxCc/1NZXR5TeOL44z+M=
Output for 5.4.2
IdcZpc6t/v5rmcGoI2hvUne8dX8lUZvuXPcmavLtpXY=
Output for 5.4.1
P9c6hYnRPvgs79kQxYDFQTfcLuV0aQXPUnDjjRSWrIw=