random gallery image
random tutorial

..index page for the suite. It's very easy because the only thing you need to do is change the content of default.php. I don't want to create something like hello world or..

read more

random information gathering
THC Discover

Discovers interesting locations, paths and data of a website

more about this module
more of this category
more modules

HackSuite File Library
File Library
Here you can find the latest files and structure of the THC HackSuite, note that if you have an earlier version of the suite it's not recommended to update files manually. Instead you should overwrite your existing HackSuite environment.
/* Class for fetching RSS Feeds */

class lastRSS {
$default_cp 'UTF-8';
$CDATA 'nochange';
$cp '';
$items_limit 0;
$stripHTML False;
$date_format '';

$channeltags = array ('title''link''description''language''copyright''managingEditor''webMaster''lastBuildDate''rating''docs');
$itemtags = array('title''link''description''author''category''comments''enclosure''guid''pubDate''source');
$imagetags = array('title''url''link''width''height');
$textinputtags = array('title''description''name''link');

Get ($rss_url) {
$result $this->Parse($rss_url);
        if (
$result$result['cached'] = 0;
// return result
return $result;
my_preg_match ($pattern$subject) {
// start regullar expression

// if there is some result... process it and return it
if(isset($out[1])) {
// Process CDATA (if present)
if ($this->CDATA == 'content') { // Get CDATA content (without CDATA tag)
$out[1] = strtr($out[1], array('<![CDATA['=>''']]>'=>''));
            } elseif (
$this->CDATA == 'strip') { // Strip CDATA
$out[1] = strtr($out[1], array('<![CDATA['=>''']]>'=>''));

// If code page is set convert character encoding to required
if ($this->cp != '')
//$out[1] = $this->MyConvertEncoding($this->rsscp, $this->cp, $out[1]);
$out[1] = iconv($this->rsscp$this->cp.'//TRANSLIT'$out[1]);
// Return result
return trim($out[1]);
        } else {
// if there is NO result, return empty string
return '';

unhtmlentities ($string) {
// Get HTML entities table
$trans_tbl get_html_translation_table (HTML_ENTITIESENT_QUOTES);
// Flip keys<==>values
$trans_tbl array_flip ($trans_tbl);
// Add support for &apos; entity (missing in HTML_ENTITIES)
$trans_tbl += array('&apos;' => "'");
// Replace entities by values
return strtr ($string$trans_tbl);

Parse ($rss_url) {
// Open and load RSS file

        // CURL mod
$ch curl_init();
$rss_content curl_exec($ch);

$rss_content ) {
// End CURL mod

            // Parse document encoding
$result['encoding'] = $this->my_preg_match("'encoding=[\'\"](.*?)[\'\"]'si"$rss_content);
// if document codepage is specified, use it
if ($result['encoding'] != '')
$this->rsscp $result['encoding']; } // This is used in my_preg_match()
            // otherwise use the default codepage
$this->rsscp $this->default_cp; } // This is used in my_preg_match()

            // Parse CHANNEL info
$this->channeltags as $channeltag)
$temp = @$this->my_preg_match("'<$channeltag.*?>(.*?)</$channeltag>'si"$out_channel[1]);
                if (
$temp != ''$result[$channeltag] = $temp// Set only if not empty
// If date_format is specified and lastBuildDate is valid
if ($this->date_format != '' && ($timestamp strtotime($result['lastBuildDate'])) !==-1) {
// convert lastBuildDate to specified date format
$result['lastBuildDate'] = date($this->date_format$timestamp);

// Parse TEXTINPUT info
// This a little strange regexp means:
                // Look for tag <textinput> with or without any attributes, but skip truncated version <textinput /> (it's not beggining tag)
if (isset($out_textinfo[2])) {
$this->textinputtags as $textinputtag) {
$temp $this->my_preg_match("'<$textinputtag.*?>(.*?)</$textinputtag>'si"$out_textinfo[2]);
                    if (
$temp != ''$result['textinput_'.$textinputtag] = $temp// Set only if not empty
// Parse IMAGE info
            if (isset(
$out_imageinfo[1])) {
$this->imagetags as $imagetag) {
$temp $this->my_preg_match("'<$imagetag.*?>(.*?)</$imagetag>'si"$out_imageinfo[1]);
                    if (
$temp != ''$result['image_'.$imagetag] = $temp// Set only if not empty
// Parse ITEMS
preg_match_all("'<item(| .*?)>(.*?)</item>'si"$rss_content$items);
$rss_items $items[2];
$i 0;
$result['items'] = array(); // create array even if there are no items
foreach($rss_items as $rss_item) {
// If number of items is lower then limit: Parse one item
if ($i $this->items_limit || $this->items_limit == 0) {
$this->itemtags as $itemtag) {
$temp $this->my_preg_match("'<$itemtag.*?>(.*?)</$itemtag>'si"$rss_item);
                        if (
$temp != ''$result['items'][$i][$itemtag] = $temp// Set only if not empty
// Strip HTML tags and other bullshit from DESCRIPTION
if ($this->stripHTML && $result['items'][$i]['description'])
$result['items'][$i]['description'] = strip_tags($this->unhtmlentities(strip_tags($result['items'][$i]['description'])));
// Strip HTML tags and other bullshit from TITLE
if ($this->stripHTML && $result['items'][$i]['title'])
$result['items'][$i]['title'] = strip_tags($this->unhtmlentities(strip_tags($result['items'][$i]['title'])));
// If date_format is specified and pubDate is valid
if ($this->date_format != '' && ($timestamp strtotime($result['items'][$i]['pubDate'])) !==-1) {
// convert pubDate to specified date format
$result['items'][$i]['pubDate'] = date($this->date_format$timestamp);
// Item counter

$result['items_count'] = $i;
// Error in opening return False
powered by
site stats
cms statistics:
version: 0.6.0
downloads: 3869
native: 26
modules: 21
apps: 2
support development
It takes lots of calories in order to create new things for the hacksuite, so it would be grand if you could buy me a protein shake or extra energy to keep me going. Thanks!
We are not responsible for any direct or indirect damage caused by abusing the tools provided on hacksuite.com. The suite is developed for educational purposes, use at your own risk!
Created by Remco Kouw. Powered by protein shakes and a high calorie diet.