Bump In The Night

Started on the old forum in November 2008 · view the original in the archive · old links redirect here

1 reply · 369 views · started 18 years ago · 1 min read

2 participants
something else Fellow · 2,296 posts #1

Im bored so heres something you may want....
wml admnproc

//////////////////////////////////////////bump
else if($action=="bump")
{
  $tid = $_GET["tid"];
  $fid = getfid($tid);
  $fname = getfname($fid);
  $crdate = time(); 
  addonline(getuid_sid($sid),"admin cp","");
  echo "<card id=\"main\" title=\"$sitename\">";
  echo "<p align=\"center\">";

    $res = mysql_query("UPDATE ibwf_topics SET lastpost='".$crdate."' WHERE id='".$tid."'");
    if($res)
        {
          echo "<img src=\"../images/ok.gif\" alt=\"o\"/>Topic Bumped Successfully
";
        }else{
          echo "<img src=\"../images/notok.gif\" alt=\"x\"/>Database Error!
";
        }
 
   echo "

<a href=\"index.php?action=viewtpc&sid=$sid&tid=$tid&go=last\">View Topic</a>";
   echo "

<a href=\"index.php?action=viewfrm&sid=$sid&fid=$fid\">$fname</a>
";
   echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"../images/home.gif\" alt=\"*\"/>Home</a>";
   echo "</p></card>";
}

xhtml admnproc

//////////////////////////////////////////bump
else if($action=="bump")
{
  $tid = $_GET["tid"];
  $fid = getfid($tid);
  $fname = getfname($fid);
  $crdate = time(); 
  addonline(getuid_sid($sid),"admin cp","");
  echo "<head>";
  echo "<title>$sitename</title>";
  echo "</head>";
  echo "<body>"; 
  echo "<div>
Bump Topic
</div>"; 
  echo "<p align=\"center\">";

    $res = mysql_query("UPDATE ibwf_topics SET lastpost='".$crdate."' WHERE id='".$tid."'");
    if($res)
        {
          echo "<img src=\"../images/ok.gif\" alt=\"o\"/>Topic Bumped Successfully
";
        }else{
          echo "<img src=\"../images/notok.gif\" alt=\"x\"/>Database Error!
";
        }
 
   echo "

<a href=\"index.php?action=viewtpc&sid=$sid&tid=$tid&go=last\">View Topic</a>";
   echo "

<a href=\"index.php?action=viewfrm&sid=$sid&fid=$fid\">$fname</a>
";
   echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"../images/home.gif\" alt=\"*\"/>Home</a>";
   echo "</p>";
   echo "</body>";
   exit();
}

(topic options) usage:

if (isadmin(getuid_sid($sid))){
echo "<a href=\"admproc.php?action=bump&sid=$sid&tid=$tid\">Bump Topic</a>
";
}

😛

djlee Developer · 224 posts #2

in the admnproc scripts change

else if($action=="bump")

to

else if($action=="bump" && isadmin(getuid_sid($sid)))

since this is now publicly available code its not hard for someone to craft the URL required to bump topics

Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close