The CPG-Nuke security requirements
Start Nytt Emne   Svar på Emne   Utskriftsvennlig side     Forum HovedsidenAnnouncements
Av Innlegg
DJ Maze
Developer


Ble medlem: Apr 19, 2004
Innlegg: 5668
Bosted: http://tinyurl.com/5z8dmv

InnleggTittel: The CPG-Nuke security requirements
Skrevet: Man Apr 19, 2004 7:24 pm
Svar med Sitat

When you have made any cool content for CPG-Nuke or PHP-Nuke for use in CPG-Nuke we need you to understand the following "security requirements" or we won't accept your add-on.
Although external Posting protection is blocking a lot, we still want you to develop secure code.
  1. Database
    1. The queries may not contain global variables or must be checked on their value for intvar(), stringlength and specialchars.
    2. If a variable may not contain HTML or PHP use our Fix_Quotes($var, 1) function to get rid of them.
    3. Only sql function calls using $db-> are accepted. The old sql functions like sql_num_rows won't be accepted and are a security breach.
  2. User & Admin
    1. Although the old function still exists to be compatible with old modules, we won't accept files that use the cookiedecode($user) function or decode the $user themselves. Use the global $userinfo instead which already contains all data of the visitor, member or not.
    2. Never decode $admin but check if the "admin" realy is a admin thru is_admin(). is_admin() returns the admin 'aid' (name) if the 'visitor' is administrator. As of 8.3 and up you can check if the admin is allowed to administer a module by using can_admin('module_name').
  3. File Access
    1. Protect your files against outside calls like /yourfile.php or a other script that runs a include/require from another host.
    2. Only calls to cms files may be made using require_once() or require() because include() and include_once() don't report absence of the file properly


DJ Maze's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Fedora 12 / 2.2.15 / 5.1.47 / 5.3.3 / CVS


Sist endret av DJ Maze den Søn Okt 03, 2004 2:58 am, endret 6 ganger totalt
Til Toppen
Vis Medlemets Profil Besøk Medlemets Nettside Yahoo Messenger
nomaed
Newbie


Ble medlem: Apr 20, 2004
Innlegg: 10

InnleggTittel: Re: The CPG-Nuke security requirements
Skrevet: Ons Apr 21, 2004 11:14 am
Svar med Sitat

What about making it work with register_globals=off, and without exporting the $_COOKIE, $_POST, $_GET and other superglobals to variables?

nomaed's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
winXP
Til Toppen
Vis Medlemets Profil Besøk Medlemets Nettside
DJ Maze
Developer


Ble medlem: Apr 19, 2004
Innlegg: 5668
Bosted: http://tinyurl.com/5z8dmv

InnleggTittel: Re: The CPG-Nuke security requirements
Skrevet: Ons Apr 21, 2004 12:48 pm
Svar med Sitat

That's a massive work which will break our new GoogleTap,
but we are heading that way more and more already.

I know GoogleTap is silly and a webpage is already shown correctly by search engines, but people think googletap works to index their pages better Forvirret


DJ Maze's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Fedora 12 / 2.2.15 / 5.1.47 / 5.3.3 / CVS
Til Toppen
Vis Medlemets Profil Besøk Medlemets Nettside Yahoo Messenger
TRANCEBUDHA
Newbie


Ble medlem: Apr 21, 2004
Innlegg: 40

InnleggTittel: Re: The CPG-Nuke security requirements
Skrevet: Tor Apr 22, 2004 6:47 pm
Svar med Sitat

Quote:

I know GoogleTap is silly and a webpage is already shown correctly by search engines, but people think googletap works to index their pages better

So i dont need to activate the google tap? heres my situation my host (prodigy.mx) didnt install for me the mod_rewrite for apache nor the isapi_rewrite for iis so i was thinking of chaning my host for correct index of my site, but i read this and is a different thing now.

can i be peacefull for my indexing issue?

thanks in advance

_________________
FEEL FREE TO VISIT ME AT

WWW.DISHLATINO.NET

TRANCEBUDHA's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
XP/IIS/MYSQL/PHP 4
Til Toppen
Vis Medlemets Profil Besøk Medlemets Nettside
DJ Maze
Developer


Ble medlem: Apr 19, 2004
Innlegg: 5668
Bosted: http://tinyurl.com/5z8dmv

InnleggTittel: Re: The CPG-Nuke security requirements
Skrevet: Tor Apr 22, 2004 7:12 pm
Svar med Sitat

www.google.com/search?...tnG=Search
_________________
There are two paths, the short one and the long one.
When you choose the short path you will notice it takes longer then the long path.
So READ the FAQ and Wiki first Rekke tunge

DJ Maze's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Fedora 12 / 2.2.15 / 5.1.47 / 5.3.3 / CVS
Til Toppen
Vis Medlemets Profil Besøk Medlemets Nettside Yahoo Messenger
anor
Newbie


Ble medlem: Apr 22, 2004
Innlegg: 4

InnleggTittel: Re: The CPG-Nuke security requirements
Skrevet: Tor Apr 22, 2004 7:31 pm
Svar med Sitat

Erm the correct way too see how many pages google has spiderd and accepted is by doing the following:

www.google.com/search?...pgnuke.com

For those who want too see there own site, do the following in google.

Type in the search field the following:
allinurl:yourdomain.com site:www.yourdomain.com (Offcourse change yourdomain.com too your domain Smil ).

Btw Djmaze why isn't that when Googletap, gt-nextgen, spiders index it better? I think it does, but probally only because the file names are shorter. (Instead of modules.php?name=Forums or index.php?name=Forums you will probally have forums.html)


anor's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Linux/1.3.29/4.0.18-standard/4.3.4
Til Toppen
Vis Medlemets Profil Besøk Medlemets Nettside
TRANCEBUDHA
Newbie


Ble medlem: Apr 21, 2004
Innlegg: 40

InnleggTittel: Re: The CPG-Nuke security requirements
Skrevet: Tor Apr 22, 2004 7:48 pm
Svar med Sitat

thanks that help alot

extreme newbie

_________________
FEEL FREE TO VISIT ME AT

WWW.DISHLATINO.NET

TRANCEBUDHA's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
XP/IIS/MYSQL/PHP 4
Til Toppen
Vis Medlemets Profil Besøk Medlemets Nettside
Phoenix
Site Admin


Ble medlem: Apr 19, 2004
Innlegg: 8723
Bosted: Netizen

InnleggTittel: Re: The CPG-Nuke security requirements
Skrevet: Fre Apr 23, 2004 1:33 am
Svar med Sitat

I'm not sure that it's the length that bothers search engines (DJ already demonstrated this on previous forum), so much as the use of '?'.

The other area where it definitely helps is when you use GT to make multi level sub-directories seem to be root directory files - this means you have a better chance of getting 'deep indexed' a lot sooner.

GT is not just for 'phpnuke' sites - I also use it on non-nuke sites and it does make a big difference.

The other aspect is that it helps when you cross-reference sites - it's much easier to type site2.com/file.html as a link on site1.com than something that is 200 characters long e.g. when you want to submit your links to other sites. Kuul

Having just done this, I'm not sure if this discussion should be attached here Spørsmål

_________________
DonationsPro for DragonflyCMS, SMF, MyBB, vBulletin

Phoenix's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Til Toppen
Vis Medlemets Profil Besøk Medlemets Nettside
DJ Maze
Developer


Ble medlem: Apr 19, 2004
Innlegg: 5668
Bosted: http://tinyurl.com/5z8dmv

InnleggTittel: Re: The CPG-Nuke security requirements
Skrevet: Fre Apr 23, 2004 1:41 am
Svar med Sitat

Ok i've opened a new forum in our second forum for googletap feature in cpgnuke cpgnuke.com/index.php?...um&f=9

DJ Maze's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Fedora 12 / 2.2.15 / 5.1.47 / 5.3.3 / CVS
Til Toppen
Vis Medlemets Profil Besøk Medlemets Nettside Yahoo Messenger
Dashe
Newbie


Ble medlem: Mai 11, 2004
Innlegg: 8
Bosted: Ireland

InnleggTittel: Re: The CPG-Nuke security requirements
Skrevet: Tor Mai 20, 2004 11:02 am
Svar med Sitat

Hi I am thinking of releasing some scripts for CPG-Nuke and was wondering if you could just clear up 3 things for me.
DJMaze wrote:
Before any try to decode $admin check if "admin" realy is a admin thru is_admin($user), and then decode the data to a other variable not $admin itself.
I didnt quite understand this, is is supposed to be is_admin($user) and not is_admin($admin), if this is correct could you explain why?
DJMaze wrote:
Beshure echoed variables are set internal and don't use global variables that could be set thru a POST or GET command to echo for example: $nukeuser[1]
I didnt understand that would you be able to explain possible with and example of what to do and what not to do.
DJMaze wrote:
Protect your files against outside calls like /yourfile.php or a other script that runs a include from another host.
Again I didnt understand what you wanted done here would you be able to explain this as well, again with an example.

Thanks very much, just want to make sure that I am coding it the way you want it done. Smil


Dashe's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Why is this not allowed to be blank?
Til Toppen
Vis Medlemets Profil Besøk Medlemets Nettside
DJ Maze
Developer


Ble medlem: Apr 19, 2004
Innlegg: 5668
Bosted: http://tinyurl.com/5z8dmv

InnleggTittel: Re: The CPG-Nuke security requirements
Skrevet: Tor Mai 20, 2004 11:36 am
Svar med Sitat

Yeah it should be is_admin($admin) i typed it wrong Forvirret

For example you have a $_POST[] and people use
PHP:
echo $_POST[];
before you do that run a proper check of what the $_POST should contain.
For example: htmlspecialchar($_POST[]) or intval($_POST[]) this will prevent people inserting malicious code into the database or output.

About XSS:
say you have a variable $file and then you run include($file) be shure $file can't be set thru $_GET or $_POST or if it must then check the variable
ereg('\.\.', $file)
ereg(':', $file)

_________________
There are two paths, the short one and the long one.
When you choose the short path you will notice it takes longer then the long path.
So READ the FAQ and Wiki first Rekke tunge

DJ Maze's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Fedora 12 / 2.2.15 / 5.1.47 / 5.3.3 / CVS
Til Toppen
Vis Medlemets Profil Besøk Medlemets Nettside Yahoo Messenger
Dashe
Newbie


Ble medlem: Mai 11, 2004
Innlegg: 8
Bosted: Ireland

InnleggTittel: Re: The CPG-Nuke security requirements
Skrevet: Tor Mai 20, 2004 12:37 pm
Svar med Sitat

Thanks

Dashe's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Why is this not allowed to be blank?
Til Toppen
Vis Medlemets Profil Besøk Medlemets Nettside
grebo
Nice poster


Ble medlem: Apr 21, 2004
Innlegg: 116
Bosted: Vancouver, Canada

InnleggTittel: Re: The CPG-Nuke security requirements
Skrevet: Tor Mai 20, 2004 2:52 pm
Svar med Sitat

Dashe, If you are rewriting your scripts JAG_Online and JAG_virus, let me know and I can remove my download of the versions I released for cpg.
_________________
Mommy What's a Grebo???

grebo's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
?
Til Toppen
Vis Medlemets Profil Besøk Medlemets Nettside
Vis Innlegg fra:   
Start Nytt Emne   Svar på Emne   Utskriftsvennlig side     Forum HovedsidenAnnouncements Alle klokkeslett er GMT
Side 1 av 1


Gå til:  
Du kan ikke starte nye emner i dette forumet
Du kan ikke svare på emner i dette forumet
Du kan ikke endre dine egne innlegg i dette forumet
Du kan ikke slette dine egne innlegg i dette forumet
Du kan ikke delta i avstemninger i dette forumet
Du kan ikke legge til filer i dette forumet
Du kan ikke laste ned filer fra dette forumet

Dedicated Server & Bandwidth Sponsored by DedicatedNOW
User Info [x]

Velkommen Anonym

Brukernavn
Passord
(Registrer)

Last CVS commits [x]

Languages [x]

Community [x]

Support for DragonflyCMS in a other languages:

Deutsch
Español

X-links [x]
UltraEdit Browse Happy logo Firefox MySQL PostgreSQL Valid CSS! Valid XHTML 1.0! Unicode Encoded Badge NukeBiz Resources Raven DragonflyCMS Dedicated Now InsideSupport Lampe Berger

Preview theme [x]
Each user can view the site with a different theme.
Themes marked with a * also change the forum look.


You are seeing squares or questionmarks on this page?

All content of this website is copyrighted by the Creative Commons NC-SA
The logos and trademarks used on this site are the property of their respective owners
We are not responsible for comments posted by our users, as they are the property of the poster.
Our server runs on a P3 1.2GHz with 512MB RAM with no accelerators
Support GoPHP5.org
Side Generering tok 0.5448 sekunder og 19 Database Oppkall på 0.0371 sekunder
Memory Usage: 3.01 MB
Interactive software released under GNU GPL, Code Credits, Privacy Policy