Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- // Coded by me (Zeerx7)
- // XploitSec-ID
- error_reporting(0);
- class ssl_cek{
- var $url;
- var $path;
- var $output;
- public function ssl($dom){
- // Set host and port.
- //$host = 'google.com';
- $host = $dom;
- $port = 443;
- // Initiate a socket connection with 'example.com' and check the result.
- $fp = fsockopen('ssl://'. $host, $port, $errno, $errstr, 30);
- $result = ($fp) ? 1 : 0;
- if($result == 1){
- $res = "https://$host".$this->path;
- echo $res;
- $this->save($this->output,$res."\n");
- }else{
- $res = "http://$host".$this->path;
- echo $res;
- $this->save($this->output,$res."\n");
- }echo "\n";
- }
- public function parse($url){
- //$url = $this->url;
- if(!preg_match("#http://|https://#",$url)){
- $url = 'http://'.$url;
- }
- $dom = parse_url($url);
- $this->path = $dom['path'];
- $dom = $dom['host'];
- $this->ssl($dom);
- }
- public function execute(){
- echo $this->banner();
- echo "Input File: ";
- $A = trim(fgets(STDIN));
- if(file_exists($A)){
- echo "Input Name Output: ";
- $this->output = trim(fgets(STDIN));
- $pausiGans = trim(file_get_contents($A));
- $pausi_ = explode("\n",$pausiGans);
- foreach($pausi_ as $ganteng => $banget){
- $this->parse(trim($banget));
- }
- }else{ echo "File Not Found\n"; }
- }
- public function banner(){
- return "
- ,',',',',',',',
- Coded by Zeerx7
- XploitSec-ID
- ',',',',',',','
- ";
- }
- public function save($a,$b){
- $a = fopen($a,'a+');
- fwrite($a,$b);
- fclose($a);
- }
- }
- $pausi = new ssl_cek;
- $pausi->execute();
Add Comment
Please, Sign In to add comment