Advertisement
Guest User

Untitled

a guest
Mar 12th, 2019
127
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.74 KB | None | 0 0
  1. private $username;
  2. private $password;
  3. protected function Login(){
  4. $user = hash('sha256', $this->username);
  5. $pass = hash('sha256', $this->password);
  6. $this query = "..."
  7. ...
  8. }
  9.  
  10. $searchstring = explode(' ', $search);
  11. //.... Some lines of PHP code... and the resulting query is: ...
  12. $this->query = "SELECT... WHERE name LIKE 'DELETE%' OR name LIKE 'FROM%' ";
  13. $this->query.= " OR name LIKE 'USERS%' OR name LIKE 'WHERE%' OR name LIKE '1%'";
  14.  
  15. $query= mysqli_real_escape_string($database_connection, $user)
  16.  
  17. $query = mysqli_real_escape_string($database_connection, trim($user))
  18.  
  19. function mssql_escape($data) {
  20. if(is_numeric($data))
  21. return $data;
  22. $unpacked = unpack('H*hex', $data);
  23. return '0x' . $unpacked['hex'];
  24. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement