From <script>alert('hello');<, 7 Years ago, written in PHP.
- view diff
Embed
  1. if (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN') {
  2. $command = 'systeminfo'; //Print out Windows System Information
  3. $output = shell_exec($command);
  4. echo $output;
  5. } else {
  6. $command = 'lshw'; //Print out Linux System Hardware Information
  7. $output = shell_exec($command);
  8. echo $output;
  9. }