Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /**
- *
- * @ This file is created by deZender.Net
- * @ deZender (PHP5 Decoder for SourceGuardian & phpSHIELD)
- *
- * @ Version : 1.1.6.0
- * @ Author : DeZender
- * @ Release on : 02.06.2013
- * @ Official site : http://DeZender.Net
- *
- */
- function cam_link($cam, $hostname, $port) {
- $direct = 0;
- $fd = fopen( . '/srv/etc/direct.' . $cam, 'r' );
- $direct = fgets( $fd, 4096 );
- $direct = chop( $direct );
- fclose( $fd );
- $remoteuser = $_SERVER['PHP_AUTH_USER'];
- $camnr = substr( $cam, 3 );
- if ($direct) {
- $ipdata = . '/srv/etc/ip.' . $cam;
- $fd = fopen( $ipdata, 'r' );
- $ip = fgets( $fd, 4096 );
- $port = fgets( $fd, 4096 );
- $user = fgets( $fd, 4096 );
- $pass = fgets( $fd, 4096 );
- fclose( $fd );
- $ip = chop( $ip );
- $port = chop( $port );
- $user = chop( $user );
- $pass = chop( $pass );
- if (has_cam_rights( $remoteuser, $camnr )) {
- if ($fstype = get_feature( $remoteuser, 'ss_user_cam_link' )) {
- print ( . '<a href="http://' . $ip . ':' ) . $port . '" class=link_button target=_BLANK>Live Stream</a>
- ';
- }
- }
- } else {
- if (has_cam_rights( $remoteuser, $camnr )) {
- if ($fstype = get_feature( $remoteuser, 'ss_user_cam_link' )) {
- print ( . '<a href="http://' . $hostname . ':' ) . $port . '" class=link_button target=_BLANK>Live Stream</a>
- ';
- }
- }
- }
- if (has_cam_rights( $remoteuser, $camnr )) {
- $permanentjpg = read_cam_permanent_jpg( $cam );
- if ($permanentjpg) {
- print . '<a href="show-pictures-permanent.pml?cam=' . $cam . '&showpics=on&showfile=off" class=link_button>Single Frames</a>
- ';
- }
- }
- }
- function pic_width_cam($cam) {
- $size = getimagesize( . '/srv/www/htdocs/' . $cam . '/lastsnap.jpg' );
- $width = $size[0];
- return $width;
- }
- function pic_height_cam($cam) {
- $size = getimagesize( . '/srv/www/htdocs/' . $cam . '/lastsnap.jpg' );
- $height = $size[1];
- return $height;
- }
- function cam_pictures($cam, $remoteuser, $stream) {
- $fd = fopen( . '/srv/etc/' . $cam, 'r' );
- $buffer = fgets( $fd, 4096 );
- fclose( $fd );
- $hostname = $_SERVER['HTTP_HOST'];
- $camnr = substr( $cam, 3 );
- $port = 9000 + $camnr;
- $fd = fopen( . '/srv/etc/location.' . $cam, 'r' );
- $location = fgets( $fd, 4096 );
- $location = substr( $location, 0, 22 );
- fclose( $fd );
- print '<table border=0 cellpadding=0 cellspacing=0>
- ';
- print '<tr><td>
- ';
- print '<table border=0 cellpadding=0 cellspacing=0>
- ';
- print '<tr valign=top><td background="/img/td-back.jpg" height=14 width=144 bgcolor=#000066 valign=middle align=left>
- ';
- print . '<a href="show-movies.pml?cam=' . $cam . '&days=2&ujava=' . $stream . '" target="_top" class=homes>
- ';
- print . ' ' . $camnr . '. ' . $location . '</a>
- ';
- print '</td><td background="/img/td-back.jpg" height=14 bgcolor=#000066 align=right valign=middle nowrap>
- ';
- $size = getimagesize( . '/srv/www/htdocs/' . $cam . '/lastsnap.jpg' );
- $vwidth = $size[0];
- $vheight = $size[1];
- $fwidth = $vwidth;
- $fheight = $vheight;
- if (has_cam_rights( $remoteuser, $camnr )) {
- print . '<a onclick="javascript:focusall();" class=menuw href="javascript:var win' . $cam . '=window.open(\'/picframe.pml?cam=' . $cam . '&ujava=' . $stream . '\',\'SingleCam' . $cam . '\',';
- print . '\'width=' . $fwidth . ',height=' . $fheight . ',location=no,scrollbars=no,toolbar=no,menubar=no\');">';
- print '<img src="/img/csk.gif" border=0></a>';
- } else {
- print '<img src="/img/dummy.gif" width=16 height=2 border=0></a>';
- }
- print '</td></tr></table>
- ';
- print '</td></tr>
- ';
- print '<tr><td valign=top>
- ';
- print '<center>
- ';
- if ($buffer == 1) {
- $fd = fopen( . '/srv/etc/' . $cam . '.timetable', 'r' );
- if ($fd) {
- $buffer2 = fgets( $fd, 4096 );
- } else {
- $buffer2 = 2;
- }
- fclose( $fd );
- if ($buffer2 == 0) {
- $outputwidth = 160;
- $outputheight = $vheight / ( $vwidth / $outputwidth );
- print . '<a href="show-movies.pml?cam=' . $cam . '&days=2&ujava=' . $stream . '" target="_top">
- ';
- print . '<img src="/getsnapshot.pml?cam=' . $cam . '" border=0 width=' . $outputwidth . ' height=' . $outputheight . '></a><br>
- ';
- ob_flush( );
- flush( );
- } else {
- if (has_cam_rights( $remoteuser, $camnr )) {
- if ($stream == '1') {
- $https = $_SERVER['HTTPS'];
- $host_port = $_SERVER['HTTP_HOST'];
- if ($https == 'on') {
- $proto = 'https';
- } else {
- $proto = 'http';
- }
- $stackingslavestatus = stackingslavestatus( );
- if (strcmp( $stackingslavestatus, '1' ) == 0) {
- $redirect = $_SERVER['REDIRECT_URL'];
- $path = explode( '/', $redirect );
- $unitpath = $path[1];
- $lpath = $unitpath . '/l' . $camnr;
- } else {
- $unitpath = '';
- $lpath = 'l' . $camnr;
- }
- $camurl = ( ( . $proto . '://' . $host_port . '/' ) . $lpath . '/' );
- print '<applet code="com.charliemouse.cambozola.Viewer" ';
- print 'archive="/cambozola.jar" ';
- $theight = $vheight / ( $vwidth / 160 );
- $theight = sprintf( '%d', $theight );
- print . 'width="160" height="' . $theight . '">
- ';
- print . '<param name="url" value="' . $camurl . '">
- ';
- print '</applet>
- ';
- } else {
- if ($stream == '2') {
- $outputwidth = 160;
- $outputheight = $vheight / ( $vwidth / $outputwidth );
- print . '<a href="show-movies.pml?cam=' . $cam . '&days=2&ujava=' . $stream . '" target="_top">';
- print . '<img onError="document.images[\'cam' . $camnr . '\'].src=\'/img/retrying.jpg\';setTimeout(\'document.images[\'cam' . $camnr . '\'].src=/l' . $camnr . '/\',10000);" src="/l' . $camnr . '/" border=0 width="' . $outputwidth . '" height="' . $outputheight . '" name="cam' . $camnr . '"></a>
- ';
- ob_flush( );
- flush( );
- } else {
- $feature = 'ss_delay';
- $fdelay = get_feature( $remoteuser, $feature );
- print . '<a href="show-movies.pml?cam=' . $cam . '&days=2&ujava=' . $stream . '" target="_top">
- ';
- if (strpos( $fdelay, 'not_defined' ) !== false) {
- print . '<img onload=setTimeout("reloadcam' . $camnr . '()';
- } else {
- $fdelay = $fdelay * 1000;
- print ( . '<img onload=setTimeout("reloadcam' . $camnr . '()",' . $fdelay . ')' );
- }
- $theight = $vheight / ( $vwidth / 160 );
- $theight = sprintf( '%d', $theight );
- print . ' onError="document.images[\'cam' . $camnr . '\'].src=\'/img/retrying.jpg\';setTimeout(\'reloadcam' . $camnr . '()\',10000);" onAbort=setTimeout(\'reloadcam' . $camnr . '()\',10000) name="cam' . $camnr . '" src="/cgi-bin/nph-getpic?c=' . $camnr . '&w=' . $vwidth . '&h=' . $vheight . '&o=160&q=65" width="160" height="' . $theight . '" border=0></a>
- ';
- }
- }
- } else {
- print '<img src="/img/no-access-320.jpg" border=0 width=160 height=120>
- ';
- }
- }
- } else {
- if (has_cam_rights( $remoteuser, $camnr )) {
- print . '<a href="show-movies.pml?cam=' . $cam . '&days=2&ujava=' . $stream . '" target="_top">
- ';
- print '<img src="/img/c-mor-dummy.jpg" width="160" height="120" border=0></a>
- ';
- } else {
- print '<img src="/img/no-access-320.jpg" border=0 width=160 height=120>
- ';
- }
- }
- ..................................................................
- ..........................
- ..........
Advertisement
Add Comment
Please, Sign In to add comment