webForumDet fria alternativet

konstiga meddelande i gästboken

PHP

2 svar · 399 visningar · startad av mr.mainline

Medlem sedan feb. 2003777 inlägg
Frågan#1

Kolla på denna länk:http://www.ridgebowshankook.com/gastbok/guestbook.php dår men massa konstiga meddelande,är det någon som vet varför??

Medlem sedan jan. 20016 874 inlägg
#2

Kolla denna tråden: http://www.webforum.nu/showthread.php?t=129128

Medlem sedan feb. 2003777 inlägg
#3

Tänkte prova detta:

What you as a site admin need to do to be 100% safe is strip carriage returns (\r) and liefeed characters (\n) from form fields in your cgi scripts. How to actually do this depends on the language used in your cgi. In the case of perl, you could do it with a regular expression this way:

$field =~ s/\r/ /g;
$field =~ s/\n/ /g;

for each field used in an email.

Some clarification on questions posted: even if your forms are hard-coded to send you the email, you are still possibly vulnerable to this attack. Adding additional header lines, including a BCC: lists is possible whenever an unchecked field is used in the header of an email. Commonly with cgi forms on the Internet, the subject line, which is part of the email headers, comes from a cgi posted variable and hence can be exploited.

men vilken php funktion ska jag använda??

262 ms totalt · 4 externa anrop · v20260731065814-full.e96017d9
123 ms — deklarationer (db)
0 ms — hämta statistik (cache)
132 ms — hämta tråd, inlägg och bilagor (db)
127 ms — ändringar (db)