 |
Menu |
 |
|
Home |
| |
|
Discussions |
| |
|
Tools |
| |
|
Affiliates |
| |
|
Content |
| |
|
Info |
| | |
|
|
|
|
 |
User Info |
 |
Membership:
Latest: MichaelSnaRe
New Today: 0
New Yesterday: 0
Overall: 9144
People Online:
Visitors: 249
Members: 0
Total: 249
|
|
|
|
|
 |
Full disclosure |
 |
Google Firebase hosting suspension / "malware distribution"bypass
CyberDanube Security Research 20251014-0 | Multiple Vulnerabilities in Phoenix Contact QUINT4 UPS
apis.google.com - Insecure redirect via __lu parameter(exploited in the wild)
Urgent Security Vulnerabilities Discovered in Mercku Routers Model M6a
Re: Security Advisory: Multiple High-Severity Vulnerabilities in Suno.com (JWT Leakage, IDOR, DoS)
Security Advisory: Multiple High-Severity Vulnerabilities in Suno.com (JWT Leakage, IDOR, DoS)
[SBA-ADV-20250730-01] CVE-2025-39664: Checkmk Path Traversal
[SBA-ADV-20250724-01] CVE-2025-32919: Checkmk Agent Privilege Escalation via Insecure Temporary Files
CVE-2025-59397 - Open Web Analytics SQL Injection
Re: [FD]Full Disclosure: CVE-2025-31200 & CVE-2025-31201 – 0-Click iMessage Chain ? Secure Enclave Key Theft, Wormable RCE, Crypto Theft
Re: Full Disclosure: CVE-2025-31200 & CVE-2025-31201 – 0-Click iMessage Chain ? Secure Enclave Key Theft, Wormable RCE, Crypto Theft
Re: Defense in depth -- the Microsoft way (part 93): SRP/SAFERwhitelisting goes black on Windows 11
Re: [FD]: "Glass Cage" – Zero-Click iMessage ? Persistent iOS Compromise + Bricking (CVE-2025-24085 / 24201, CNVD-2025-07885)
Re: [FD]Full Disclosure: CVE-2025-31200 & CVE-2025-31201 – 0-Click iMessage Chain ? Secure Enclave Key Theft, Wormable RCE, Crypto Theft
Samtools v1.22.1 Uncontrolled Memory Allocation from Large BED Intervals Causes Denial-of-Service in Samtools/HTSlib
|
|
|
|
|
|
 |
|
 |
 |
|
 |
IT Security and Insecurity Portal |
|
 |
please this code |
 |
Posted: Mon Nov 11, 2013 8:05 pm |
|
|
devilhunter |
Active user |

 |
|
Joined: Jul 12, 2013 |
Posts: 35 |
|
|
|
 |
 |
 |
|
|
|
|
|
 |
Re: please this code |
 |
Posted: Tue Nov 12, 2013 10:39 am |
|
|
vv456 |
Advanced user |

 |
|
Joined: Aug 24, 2012 |
Posts: 190 |
|
|
|
 |
 |
 |
|
devilhunter wrote: | http://pastebin.com/uwXJfppi
Thank You |
Code: | <?php
class Videos {
protected $CI = null;
protected $config = null;
function __construct($config = array( )) {
$this->CI = &get_instance( );
if (is_array( $config )) {
$this->config = $config;
}
}
function get_video($sef_uri) {
if ($data = $this->CI->videos_model->get_video( $sef_uri )) {
$detail = $data[0];
if (!existCookie( 'view_video', $detail['video_id'] )) {
if ($this->CI->videos_model->viewed_video( $detail['video_id'] )) {
insertCookie( 'view_video', $detail['video_id'] );
}
}
$detail['18age'] = 0;
$parts = array( );
$posters['posters'] = array( );
$tags['tags'] = array( );
$soundtracks['soundtracks'] = array( );
$casts['casts'] = array( );
$categories['categories'] = array( );
$list = array( );
$lists['lists'] = array( 'Wlist' => 0, 'Flist' => 0, 'Llist' => 0, 'Slist' => 0 );
$i = 11;
while ($i < count( $data )) {
if (( ( !isset( $parts['parts'][$data[$i]['part_name']] ) && !empty( $data[$i]['part_id'] ) ) && !empty( $data[$i]['part_name'] ) )) {
$unserialized_parts = unserialize( $data[$i]['part_content'] );
if (is_array( $unserialized_parts )) {
foreach ($unserialized_parts as $unserialized_part) {
if (!empty( $unserialized_part )) {
$parts['parts'][$data[$i]['part_name']][] = array( 'part_id' => $data[$i]['part_id'], 'part_content' => $unserialized_part );
continue;
}
}
}
else {
if ($data[$i]['part_name'] == 'trailer') {
$parts['parts']['trailer'] = array( 'part_id' => $data[$i]['part_id'], 'part_content' => $unserialized_parts );
}
}
}
if (( !isset( $tags['tags'][$data[$i]['tag_id']] ) && !empty( $data[$i]['tag_id'] ) )) {
$tags['tags'][$data[$i]['tag_id']] = array( 'name' => $data[$i]['tag_name'], 'sef_uri' => $data[$i]['tag_sef_uri'] );
}
if (( !empty( $data[$i]['soundtracks'] ) && empty( $soundtracks['soundtracks'] ) )) {
foreach (unserialize( $data[$i]['soundtracks'] ) as $soundtrack) {
$soundtracks['soundtracks'][] = $soundtrack;
}
}
if (( !isset( $casts['casts'][$data[$i]['cast_id']] ) && !empty( $data[$i]['cast_id'] ) )) {
if ($data[$i]['cast_type'] == 2) {
$casts['casts'][$data[$i]['cast_id']]['name'] = $data[$i]['cast_name'];
$casts['casts'][$data[$i]['cast_id']]['sef_uri'] = $data[$i]['cast_sef_uri'];
$casts['casts'][$data[$i]['cast_id']]['character'] = $data[$i]['cast_character'];
$casts['casts'][$data[$i]['cast_id']]['photo'] = (empty( $data[$i]['cast_photo'] ) ? 'http://placehold.it/50x50&text=RESIM YOK' : cast_url( $data[$i]['cast_photo'] ));
}
else {
if ($data[$i]['cast_type'] == 1) {
$casts['director']['name'] = $data[$i]['cast_name'];
$casts['director']['sef_uri'] = $data[$i]['cast_sef_uri'];
$casts['director']['photo'] = (empty( $data[$i]['cast_photo'] ) ? 'http://placehold.it/50x50&text=RESIM YOK' : cast_url( $data[$i]['cast_photo'] ));
}
}
}
if (!isset( $categories['categories'][$data[$i]['cat_id']] )) {
if (!empty( $data[$i]['cat_options'] )) {
$data[$i]['cat_options'] = unserialize( $data[$i]['cat_options'] );
if ($data[$i]['cat_options']['age'] == 1) {
$detail['18age'] = 1;
}
}
$categories['categories'][$data[$i]['cat_id']] = array( 'name' => $data[$i]['cat_name'], 'sef_uri' => $data[$i]['cat_sef_uri'] );
}
if (( !empty( $data[$i]['posters'] ) && empty( $posters['posters'] ) )) {
foreach (unserialize( $data[$i]['posters'] ) as $poster) {
if (!empty( $poster )) {
$posters['posters'][] = $poster;
continue;
}
}
}
if (( !isset( $list[$data[$i]['type']][$data[$i]['user_list_user_id']] ) && !empty( $data[$i]['user_list_user_id'] ) )) {
$list[$data[$i]['type']][$data[$i]['user_list_user_id']] = true;
if ($data[$i]['type'] == 1) {
++$lists['lists']['Llist'];
}
else {
if ($data[$i]['type'] == 2) {
++$lists['lists']['Flist'];
}
else {
if ($data[$i]['type'] == 3) {
++$lists['lists']['Wlist'];
}
else {
if ($data[$i]['type'] == 4) {
++$lists['lists']['Slist'];
}
}
}
}
}
$detail = array_merge( $detail, $parts );
$detail = array_merge( $detail, $tags );
$detail = array_merge( $detail, $soundtracks );
$detail = array_merge( $detail, $casts );
$detail = array_merge( $detail, $categories );
$detail = array_merge( $detail, $posters );
$detail = array_merge( $detail, $lists );
++$i;
}
$detail['vote_total'] = $detail['vote_good'] + $detail['vote_normal'] + $detail['vote_bad'];
unset( $detail[part_id] );
unset( $detail[part_name] );
unset( $detail[part_content] );
unset( $detail[tag_id] );
unset( $detail[tag_sef_uri] );
unset( $detail[tag_name] );
unset( $detail[cast_id] );
unset( $detail[cast_name] );
unset( $detail[cast_sef_uri] );
unset( $detail[cast_photo] );
unset( $detail[cast_character] );
unset( $detail[cast_type] );
unset( $detail[cat_id] );
unset( $detail[cat_name] );
unset( $detail[cat_sef_uri] );
unset( $detail[user_list_user_id] );
unset( $detail[type] );
unset( $detail[cat_options] );
$detail['general'] = array( 'main_category_name' => $categories['categories'][$detail['category_id']]['name'], 'short_content' => word_limiter( strip_tags( $detail['content'] ), 30 ), 'categories' => implode( ' ,', MultidimensionalArrayGetVal( $detail['categories'], 'name' ) ), 'tags' => implode( ' ,', MultidimensionalArrayGetVal( $detail['tags'], 'name' ) ), 'title' => $detail['title'], 'alternative_title' => $detail['alternative_title'] );
return $detail;
}
return false;
}
function get_last_videos($page) {
if (0 < $page) {
$offset = ( $page + 0 ) * $this->config['content_view_number'] - $this->config['content_view_number'];
}
else {
$offset = $page;
}
if ($videos = $this->CI->videos_model->get_last_videos( $offset, $this->config['content_view_number'] )) {
return $this->video_parser( $videos );
}
return FALSE;
}
function get_viewed_videos($page) {
if (0 < $page) {
$offset = ( $page + 0 ) * $this->config['content_view_number'] - $this->config['content_view_number'];
}
else {
$offset = $page;
}
if ($videos = $this->CI->videos_model->get_viewed_videos( $offset, $this->config['content_view_number'] )) {
return $this->video_parser( $videos );
}
return FALSE;
}
function get_liked_videos($page) {
if (0 < $page) {
$offset = ( $page + 0 ) * $this->config['content_view_number'] - $this->config['content_view_number'];
}
else {
$offset = $page;
}
if ($videos = $this->CI->videos_model->get_liked_videos( $offset, $this->config['content_view_number'] )) {
return $this->video_parser( $videos );
}
return FALSE;
}
function get_category_videos($cat_id, $page, $category_type) {
if (0 < $page) {
$offset = ( $page + 0 ) * $this->config['content_view_number'] - $this->config['content_view_number'];
}
else {
$offset = $page;
}
$list = array( 'last' => array( 'order' => 'videos.publish_date', 'by' => 'DESC' ), 'watch' => array( 'order' => 'videos.view', 'by' => 'DESC' ), 'like' => array( 'order' => 'videos.vote_good', 'by' => 'DESC' ), 'imdb' => array( 'order' => 'videos.imdb', 'by' => 'DESC' ) );
if (!isset( $list[$category_type] )) {
return FALSE;
}
if ($videos = $this->CI->videos_model->get_category_videos( $cat_id, $offset, $this->config['content_view_number'], $list[$category_type] )) {
return $this->video_parser( $videos );
}
return FALSE;
}
function get_tag_videos($tag_id) {
if ($videos = $this->CI->videos_model->get_tag_videos( $tag_id )) {
return $this->video_parser( $videos );
}
return FALSE;
}
function search_video($text) {
if ($videos = $this->CI->videos_model->get_search_videos( $text )) {
return $this->video_parser( $videos );
}
return FALSE;
}
function get_high_imdb_video($page) {
if (0 < $page) {
$offset = ( $page + 0 ) * $this->config['content_view_number'] - $this->config['content_view_number'];
}
else {
$offset = $page;
}
if ($videos = $this->CI->videos_model->get_high_imdb_videos( 7, $offset, $this->config['content_view_number'] )) {
return $this->video_parser( $videos );
}
return FALSE;
}
function video_parser($videos) {
foreach ($videos as $key => $value) {
$videos[$key]->image = array( 'poster' => poster_url( $videos[$key]->image ), 'thumb' => poster_thumb_url( $videos[$key]->image ) );
if (!empty( $videos[$key]->tags )) {
$tags = explode( '||', $videos[$key]->tags );
$videos[$key]->tags = array( );
foreach ($tags as $tag) {
$tag_sef_uri = explode( '::', $tag )[2];
[1];
$tag_id = ;
[0];
$tag_name = ;
$videos[$key]->tags[] = array( 'name' => $tag_name, 'sef_uri' => $tag_sef_uri );
}
}
if (!empty( $videos[$key]->categories )) {
$categories = explode( '||', $videos[$key]->categories );
$videos[$key]->categories = array( );
foreach ($categories as $category) {
$cat_sef_uri = explode( '::', $category )[2];
[1];
$cat_id = ;
[0];
$cat_name = ;
if ($cat_id == $videos[$key]->category_id) {
$videos[$key]->cat_sef_uri = $cat_sef_uri;
}
$videos[$key]->categories[] = array( 'name' => $cat_name, 'sef_uri' => $cat_sef_uri );
}
continue;
}
}
return $videos;
}
function get_heading_videos() {
$data['heading_videos'] = $this->CI->videos_model->get_heading_videos( );
if (( $data['heading_videos']['count'] < 6 && $data['heading_videos']['count'] != 0 )) {
$data['heading_videos']['videos'] = array_merge( $this->CI->videos_model->get_random_videos( 6 - $data['heading_videos']['count'] ), $data['heading_videos']['videos'] );
}
return $data['heading_videos']['videos'];
}
function get_daily_video() {
$this->CI->db->cache_on( );
$video = $this->CI->videos_model->get_daily_video( human_to_unix( date( 'Y-m-d 21:00' ) ) );
if ($video->video_id) {
$this->CI->db->cache_off( );
return $video;
}
$this->CI->db->cache_off( );
return FALSE;
}
function get_categories() {
$this->CI->db->cache_on( );
if ($categories = $this->CI->categories_model->get_categories( )) {
foreach ($categories as $category) {
$items[$category['parent']][] = $category;
}
$i = 10;
foreach ($items[0] as $item) {
$data[$i] = $item;
if (isset( $items[$item['cat_id']] )) {
foreach ($items[$item['cat_id']] as $sub_category) {
$data[$i]['sub_category'][] = $sub_category;
}
}
++$i;
}
$this->CI->db->cache_off( );
return $data;
}
$this->CI->db->cache_off( );
return FALSE;
}
function get_last_comments() {
return ($this->config['last_comments'] == 1 ? $this->CI->comments_model->get_last_comments( $this->config['last_comments_number'] ) : FALSE);
}
function get_video_part($video_id, $part_name, $page) {
if ($part = $this->CI->videos_model->get_video_part( $video_id, $part_name )) {
$data['part'] = '';
$data['part_count'] = '';
$data['one_part'] = TRUE;
if ($part_name == 'trailer') {
$data['part'] = VideoEmbedParser( (is_serialized( $part['part_content'] ) ? unserialize( $part['part_content'] ) : $part['part_content']) );
}
else {
if (is_serialized( $part['part_content'] )) {
$part_contents = unserialize( $part['part_content'] );
$page = (count( $part_contents ) < $page ? 0 : $page);
$data['part_count'] = count( $part_contents );
if (1 < $data['part_count']) {
foreach ($part_contents as $part_content) {
if (!IsEmbed( $part_content )) {
$data['one_part'] = FALSE;
continue;
}
}
if (( $data['one_part'] && $page == 0 )) {
$data['part'] = $part_contents;
}
else {
$data['part'] = VideoEmbedParser( $part_contents[$page] );
}
}
else {
$data['part'] = VideoEmbedParser( $part_contents[$page] );
}
}
}
return $data;
}
return FALSE;
}
function get_magic_videos() {
$videos = array( );
$categories = array( );
$wathced['video_id'] = array( );
$wathced['category_id'] = array( );
$lists = $this->CI->users_model->get_userlists( $this->config['user_id'] );
if ($lists['WList']) {
foreach ($lists['WList'] as $WList) {
$wathced['video_id'][] = $WList->video_id;
$wathced['category_id'][] = $WList->category_id;
}
}
if ($lists['LList']) {
foreach ($lists['LList'] as $LList) {
$wathced['video_id'][] = $LList->video_id;
$wathced['category_id'][] = $LList->category_id;
}
}
if ($lists['FList']) {
foreach ($lists['FList'] as $FList) {
$wathced['video_id'][] = $FList->video_id;
$wathced['category_id'][] = $FList->category_id;
}
}
$cast_videos = $this->CI->users_model->get_favorite_list_videos( $this->config['user_id'] );
if ($cast_videos) {
foreach ($cast_videos as $cast_video) {
if (!in_array( $cast_video->video_id, $wathced['video_id'] )) {
$videos[] = $cast_video->video_id;
continue;
}
}
}
if (( empty( $videos ) && empty( $wathced['category_id'] ) )) {
return 0 - 1;
}
return $this->CI->videos_model->get_magic_videos( $videos, $wathced['category_id'] );
}
}
if (!defined( 'BASEPATH' )) {
exit( 'No direct script access allowed' );
}
?> |
|
|
|
|
|
 |
www.waraxe.us Forum Index -> PHP script decode requests
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
All times are GMT
Page 1 of 1
|
|
|
Powered by phpBB © 2001-2008 phpBB Group
|
|
|
|
|
|