Bravo List
Register
Go Back   > Bravo List > Torrents Trackers > TBDev
Reply
  #1  
Old 10-11-16, 01:54
puppy's Avatar
puppy puppy is offline
Member
 
Join Date: Feb 2016
P2P
Posts: 12
Default TBDev
Hey guys,

I know this code is old and wrinkly and has security holes etc but I was wondering if I put the time and effort into updating a copy with mods etc weather it would be worth sharing? I am not going to promise a deadline or anything as I know there is a lot of work ahead, I have already updated the config file using a few sources to patch it up to my vision which anyone could do if they tried.

I am in mids of converting to mysqli, I have successfully already converted the dbconn() to run with mysqli I still need to update it a tad more by reading a few other sources of course. I am thinking about adding partial cms code snippets to this copy of tbdev version, so what do you think?

Have a good day
Reply With Quote
  #2  
Old 10-11-16, 12:26
TLO's Avatar
TLO TLO is offline
Senior Member
 
Join Date: May 2009
United Kingdom
Posts: 21
Default
Quote:
Originally Posted by puppy View Post
Hey guys,

I know this code is old and wrinkly and has security holes etc but I was wondering if I put the time and effort into updating a copy with mods etc weather it would be worth sharing? I am not going to promise a deadline or anything as I know there is a lot of work ahead, I have already updated the config file using a few sources to patch it up to my vision which anyone could do if they tried.

I am in mids of converting to mysqli, I have successfully already converted the dbconn() to run with mysqli I still need to update it a tad more by reading a few other sources of course. I am thinking about adding partial cms code snippets to this copy of tbdev version, so what do you think?

Have a good day
Try looking at u232 project. Mindless and co have already completed what you are suggesting. u232 is the new Tbdev
Reply With Quote
  #3  
Old 10-11-16, 22:34
puppy's Avatar
puppy puppy is offline
Member
 
Join Date: Feb 2016
P2P
Posts: 12
Default
I don't mean to be rude when I say this as it just my opinion, I use u232 already and well tbh they are a reason as to why I want to do this project as they have inspired me to attempt doing a version.
Reply With Quote
  #4  
Old 11-11-16, 12:34
Phogo's Avatar
Phogo Phogo is offline
Super MOD
 
Join Date: Jan 2008
United Kingdom
Posts: 875
Default
Quote:
Originally Posted by puppy View Post
I don't mean to be rude when I say this as it just my opinion, I use u232 already and well tbh they are a reason as to why I want to do this project as they have inspired me to attempt doing a version.
If you want to do this using an old TBDEV as a base isn't the answer.

The team responsible for u232 have put lots of hours into their releases. Why not contribute to their source on github?
Reply With Quote
  #5  
Old 11-11-16, 15:07
TLO's Avatar
TLO TLO is offline
Senior Member
 
Join Date: May 2009
United Kingdom
Posts: 21
Default
Hi m8

No offence taken, Bigjoos has just converted u232 v1 and v2 to utilise mysqli. All versions will soon all utilise it.
Reply With Quote
  #6  
Old 13-11-16, 00:39
puppy's Avatar
puppy puppy is offline
Member
 
Join Date: Feb 2016
P2P
Posts: 12
Default
Quote:
If you want to do this using an old TBDEV as a base isn't the answer.

The team responsible for u232 have put lots of hours into their releases. Why not contribute to their source on github?
I see there is FreeTSP, FreeSpirit, u-232 all based on TBDev which makes me wonder if I can do a copy myself I don't mean to offend anyone by doing this project I just wanted to see if I could attempt another version for people to consider, I will be using open source projects to utilize this goal.

PHP Code:
<?php
# ************************************************************************
# Licence Info: GPL                                                                *
# Copyright (C) 2016 Project R2                                               *
# Source Base TBDev/FreeTSP/FreeSpirit/U-232/Gazelle/MyBB       *
# Project Developer: SceneGod                                                *
# ************************************************************************

/* Disallow direct access to this file for security reasons */
if (!defined("PROJECT_R2")) {
    
  
print_r("Direct initialization of this file is not allowed.");
}

error_reporting(E_ALL);

const 
REQUIRED_PHP 50400REQUIRED_PHP_VERSION '5.4.0';

if (
PHP_VERSION_ID REQUIRED_PHP) {
    
  
print_r('PHP '.REQUIRED_PHP_VERSION.' or higher is required.');
}

if (isset(
$_SERVER["HTTP_HOST"]) &&  $_SERVER["HTTP_HOST"] == "") {
  
  
$_SERVER["HTTP_HOST"] = $_SERVER["SERVER_NAME"];
}  

define('TIME_NOW'time());
$TBDEV['time_adjust'] =  0;
$TBDEV['time_offset'] = '0'
$TBDEV['time_use_relative'] = 1;
$TBDEV['time_use_relative_format'] = '{--}, h:i A';
$TBDEV['time_joined'] = 'j-F y';
$TBDEV['time_short'] = 'jS F Y - h:i A';
$TBDEV['time_long'] = 'M j Y, h:i A';
$TBDEV['time_tiny'] = '';
$TBDEV['time_date'] = '';
/* Set the database access information as constants: */
define('DB_HOST''localhost');
define('DB_USER''root');
define('DB_PASSWORD''MagicMushrooms');
define('DB_DATABASE''project');
/* Site Settings */                              
define ('UC_USER'0);
define ('UC_POWER_USER'1);
define ('UC_ELITE_USER'2);
define ('UC_DJ_USER'3);
define ('UC_TRUSTED_USER'4);
define ('UC_VIP'5);
define ('UC_TORRENT_EDITOR'6);
define ('UC_MODERATOR'7);
define ('UC_ADMINISTRATOR'8);
define ('UC_TEAM_LEADER'9);
define ('UC_DESIGNER'10);
define ('UC_SYSOP'11);
define ('UC_CO_OWNER'12);
define ('UC_OWNER'13);
define('PATH'dirname(__FILE__).DIRECTORY_SEPARATOR);
define('ROOT_PATH'realpath(PATH.'..'.DIRECTORY_SEPARATOR).DIRECTORY_SEPARATOR);
$TBDEV['announce_urls'] = array();
$TBDEV['site_online'] = 1;
$TBDEV['baseurl'] = 'http' . (isset($_SERVER['HTTPS']) && (bool)$_SERVER['HTTPS'] == true 's' '') . '://' $_SERVER['HTTP_HOST'];
$TBDEV['announce_urls'][] = "https://'.$_SERVER['HTTP_HOST'].'/announce.php";
$TBDEV['tracker_post_key'] = 'bsghrtheu6!5y$etr';
$TBDEV['max_torrent_size'] = 1024 1024;
$TBDEV['announce_interval'] = 60 30;
$TBDEV['signup_timeout'] = 86400 3;
$TBDEV['minvotes'] = 1;
$TBDEV['max_dead_torrent_time'] = 3600;
$TBDEV['autoclean_interval'] = 1800;
$TBDEV['maxusers'] = 5000;
$TBDEV['site_email'] = "noreply@localhost";
$TBDEV['site_name'] = "Scene Club";
$TBDEV['language'] = 'en';
$TBDEV['msg_alert'] = 0;
$TBDEV['torrent_dir'] = ROOT_PATH '/torrents';
$TBDEV['sql_error_log'] = ROOT_PATH.'/logs/'.date("M_D_Y").'_sql.log';
$TBDEV['pic_base_url'] = "./pic/";
$TBDEV['stylesheet'] = "2";
$TBDEV['readpost_expiry'] = 14*86400;
$TBDEV['av_img_height'] = 100;
$TBDEV['av_img_width'] = 100;
$TBDEV['allowed_ext'] = array('image/gif''image/png''image/jpeg');
define ('BETA_VER','R2');
?>
to utilize the config file you must place this code:
PHP Code:
/* above require_once("include/config.php"); */
define('PROJECT_R2'true);

/* needs updating but works */
function dbconn($autoclean false) {

  
mysqli_connect(DB_HOSTDB_USERDB_PASSWORDDB_DATABASE) or mysqli_errno("Connection Failed: %s\n"mysqli_connect_error());
  
userlogin();

  if (
$autoclean) {
      
    
register_shutdown_function("autoclean");
  }

inside of bittorrent.php

I know you may not see my point but I am trying something different to the other sources within saying that using some code to help secure and guide me into the correct direction.
Reply With Quote
  #7  
Old 13-11-16, 05:11
fireknight's Avatar
fireknight fireknight is offline
Senior Member
 
Join Date: Aug 2010
Australia
Posts: 133
Default
Hey Puppy.

End of the day - most of the codes out there are based of TBDev ( which is based of the original TBSource code )
Both of which are outdated and full of security holes.

Having said that, they can be filled and made secure.

Good on you for starting with a very base code.
While you are updating that code - you will learn a lot ( from a coding point of view )
This is always a good thing !!

The more base codes out there - the more we all learn.
Some of us are more advanced coders that others.
But we all started somewhere.

So it is great that you want to create something from scratch.

Do not let people put you down.
Do not let people put you off.

You have a great idea, and a lot of work ahead of you.
But you are willing to give it a go.
I for one am interested in your idea, and look forward to what you create.

You V 1.0 code may not be the best.
But you will learn from it, and that will push you forward to create better.

The best way to learn is to give it your best shot, and learn from your mistakes.

You go for it.
Don't let the knockers wear you down.
Stand tall, be proud.

If you need help, do not be afraid to ask for it.
The real coders out there will offer good and solid advice, and maybe even help.
But you also have to be able to take their negative comments, as well as their positive comments.

The wanna be coders
( who have never taken on a real project - as in an one they will release to the general public )
But claim they have their own code - but it is only for sale - not for general release.
Will knock you down.

STAND TALL - well done and keep going with your project.
Reply With Quote
The Following User Says Thank You to fireknight For This Useful Post:
puppy (13-11-16)
  #8  
Old 13-11-16, 06:37
joeroberts's Avatar
joeroberts joeroberts is offline
BT.Manager Owner
 
Join Date: Jan 2008
United States
Posts: 1,989
Default
I would be putting this
PHP Code:
define('PROJECT_R2'true); 
In all the base files (index.php, browse.php,forum.php ..............)
and all the other files I would put
PHP Code:
if (!defined("PROJECT_R2")) {
    
  
print_r("Direct initialization of this file is not allowed.");

this well help a little more with securing your files.
__________________
Do not ask me to help you work on your site that is not phpMyBitTorrent
Do not ask me to make a mod for any other source
Do not Ask me to setup your site.
I will no longer help you setup your site, there is a setup script if you have trouble with it post in the forum here or in BT.Managerô forum
My Current Demo is here http://demo.btmanager.org/
Reply With Quote
The Following User Says Thank You to joeroberts For This Useful Post:
puppy (13-11-16)
  #9  
Old 13-11-16, 06:49
puppy's Avatar
puppy puppy is offline
Member
 
Join Date: Feb 2016
P2P
Posts: 12
Default
Thanks fireknight I am glad to herd your take on this project, I have gotten a pro coder from here on board to help me out with the code, I am just waiting on his response.

I understand I got alot of work ahead so today I am just reading / recoding the bittorrent script plus learning ontop. I might do an updated version without mods for a starting point as putting in multi mods would just jam it up in the updates as for now it is just me doing the work, not that I am complaining I wanted to do this so I learned what made these other sources so great today and while today is my day off work I am gonna do some research, gonna try out a few cms tricks to see if I can integrate my ideas, I am taking it slow as I have to work for living like most.

I might alter some code/files/folders so I should do a changelog.txt but I will do that after I have done my part, as stated before this is not a rush job I am taking this serious just like most would if they cared about a project they helped, created, designed etc... I just hope I am not treading on anyones feet as that is the last thing I wanna do.

Bump:
Quote:
Originally Posted by joeroberts View Post
I would be putting this
PHP Code:
define('PROJECT_R2'true); 
In all the base files (index.php, browse.php,forum.php ..............)
and all the other files I would put
PHP Code:
if (!defined("PROJECT_R2")) {
    
  
print_r("Direct initialization of this file is not allowed.");

this well help a little more with securing your files.
Thanks Joe, I never thought about doing that, but now you have pointed that idea about I will be sure to utilize that gesture.

Bump: Quick design peak -

Click the image to open in full size.

I hope you like the beginning
__________________
http://www.scene-community.com
Reply With Quote
Reply

Tags
tbdev

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



All times are GMT +2. The time now is 20:47. vBulletin skin by ForumMonkeys. Powered by vBulletin® Version 3.8.11 Beta 3
Copyright ©2000 - 2017, vBulletin Solutions Inc.