This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
# This program is part of Percona Toolkit: http://www.percona.com/software/ | |
# See "COPYRIGHT, LICENSE, AND WARRANTY" at the end of this file for legal | |
# notices and disclaimers. | |
use strict; | |
use warnings FATAL => 'all'; | |
use constant MKDEBUG => $ENV{MKDEBUG} || 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php $color = dechex(rand(0x000000, 0xFFFFFF)); ?> | |
<body style="background-color: <?php echo $color; ?>;"> | |
<h1><?php echo $color ?></h1> | |
</body> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* Run this script every 5 minutes (or 1 hour, is up to you) using a cron task */ | |
/* Edit this data*/ | |
$domain = "mydomain.com"; | |
$pass = "xxxxxx"; | |
$host = ""; // Optional, for additional hosts names like: ftp., mail. or any sub-domains. | |
/* DO NOT EDIT FROM HERE */ | |
file_get_contents("http://dynamic.name-services.com/interface.asp?command=SetDNSHost&Zone=@.$domain&DomainPassword=$pass"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Get nameserver from a domain name. | |
function getNameservers($hostname) { | |
$result = dns_get_record($hostname, DNS_NS); | |
foreach($result as $record) { | |
$return[] = $record['target']; | |
} | |
return $return; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function whois($domain) { | |
// fix the domain name: | |
$domain = strtolower(trim($domain)); | |
$domain = preg_replace('/^http:\/\//i', '', $domain); | |
$domain = preg_replace('/^https:\/\//i', '', $domain); | |
$domain = preg_replace('/^www\./i', '', $domain); | |
$domain = explode('/', $domain); | |
$domain = trim($domain[0]); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Project Title</title> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge"> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
<link href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.6/css/bootstrap.min.css" rel="stylesheet"> | |
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Options +FollowSymlinks | |
RewriteEngine On | |
RewriteCond %{REQUEST_URI} !/mantenimiento.html$ | |
RewriteCond %{REMOTE_HOST} !^999\.999\.999\.999 | |
RewriteRule $ /mantenimiento.html [R=302,L] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>CHMOD ONLINE EMULATOR</title> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<meta name="description" content="CHMOD ONLINE EMULATOR"> | |
<!-- Twitter Bootstrap --> | |
<link href="http://twitter.github.com/bootstrap/assets/css/bootstrap.css" rel="stylesheet"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function secondsToTime($seconds) { | |
// Extract days | |
$days = floor($seconds / 86400); | |
// Extract hours | |
$divisorHours = $seconds % 86400; | |
$hours = floor($divisorHours / 3600); | |
// Extract minutes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#Require root SSH access by authentication file | |
TEMPFILE=`mktemp -p /tmp` | |
HOSTNAME=`hostname` | |
MASTERS=`hostname -i` | |
REMOTE_URI="[email protected]" | |
SLAVE_PATH="/var/named/chroot/etc/" | |
for domain in `egrep '^zone' /etc/named.conf | egrep -iv "arpa|\"\." | egrep -iv "domain.com" | awk -F\" '{print $2}'` | |
do printf "zone \"${domain}\" {\n\t type slave;\n\t file \"/var/named/slaves/${domain}.db\";\n\t masters { ${MASTERS}; };\n};\n\n" |
OlderNewer