3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php // Eléments d'authentification LDAP $ldaprdn = 'admin'; // DN ou RDN LDAP $ldappass = '%00'; // Mot de passe associé // Connexion au serveur LDAP $ldapconn = ldap_connect("challenge01.root-me.org",54013) or die("Impossible de se connecter au serveur LDAP."); if ($ldapconn) { // Connexion au serveur LDAP $ldapbind = ldap_bind($ldapconn, $ldaprdn, $ldappass); // Vérification de l'authentification if ($ldapbind) { echo "Connexion LDAP réussie..."; } else { echo "Connexion LDAP échouée..."; } } ?>
based on 0A1tF
Finding entry points
Branch analysis from position: 0
Jump found. Position 1 = 8, Position 2 = 10
Branch analysis from position: 8
Jump found. Position 1 = -2
Branch analysis from position: 10
Jump found. Position 1 = 12, Position 2 = 22
Branch analysis from position: 12
Jump found. Position 1 = 19, Position 2 = 21
Branch analysis from position: 19
Jump found. Position 1 = 22
Branch analysis from position: 22
Jump found. Position 1 = -2
Branch analysis from position: 21
Jump found. Position 1 = -2
Branch analysis from position: 22
filename:       /in/FnRcn
function name:  (null)
number of ops:  23
compiled vars:  !0 = $ldaprdn, !1 = $ldappass, !2 = $ldapconn, !3 = $ldapbind
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   3     0  E >   ASSIGN                                                   !0, 'admin'
   4     1        ASSIGN                                                   !1, '%2500'
   7     2        INIT_FCALL_BY_NAME                                       'ldap_connect'
         3        SEND_VAL_EX                                              'challenge01.root-me.org'
         4        SEND_VAL_EX                                              54013
         5        DO_FCALL                                      0  $6      
         6        ASSIGN                                           $7      !2, $6
         7      > JMPNZ_EX                                         ~8      $7, ->10
   8     8    > > EXIT                                                     'Impossible+de+se+connecter+au+serveur+LDAP.'
         9*       BOOL                                             ~8      <true>
        10    >   FREE                                                     ~8
  10    11      > JMPZ                                                     !2, ->22
  13    12    >   INIT_FCALL_BY_NAME                                       'ldap_bind'
        13        SEND_VAR_EX                                              !2
        14        SEND_VAR_EX                                              !0
        15        SEND_VAR_EX                                              !1
        16        DO_FCALL                                      0  $9      
        17        ASSIGN                                                   !3, $9
  16    18      > JMPZ                                                     !3, ->21
  17    19    >   ECHO                                                     'Connexion+LDAP+r%C3%A9ussie...'
        20      > JMP                                                      ->22
  19    21    >   ECHO                                                     'Connexion+LDAP+%C3%A9chou%C3%A9e...'
        22    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 7.3.0