Jump to content

fr34k

Members
  • Posts

    39
  • Joined

  • Last visited

    Never

About fr34k

  • Birthday 07/06/1982

Profile Information

  • Gender
    Male
  • Location
    Greenville, NC, USA

fr34k's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. I'm pretty sure that the only way you can carry over sessions is either via cookie or URL. The server needs to know the client's session ID, in order to access that session-specific data. That being said, you could possibly store the session ID in your MySQL database and associate it with the client's IP address. However, this is not ideal, because it is very possible that multiple clients could be on a network that shares one public IP address. Your session information would then count for all of them.
  2. If you're concerned with speed, I would not recommend iterating. MD5 is a weaker hashing algorithm, but that doesn't mean that all hashing algorithms are outdated. You can try PHP's crypt function. There are a few different adequate hashing algorithms therein. http://us3.php.net/manual/en/function.crypt.php
  3. If memory serves, the ID for a user's PHP session is carried over from one request to another either by cookie or the session ID being sent as a parameter with the client's request (like in the URL.) Because of this, a person would be able to "reset" their session data by either deleting the cookie value or just removing the session ID from their requests (editing the ID out of the URL, etc.)
  4. Pretty simple and not foolproof, but...check the referrer with each call to your PHP script? $_SERVER['HTTP_REFERER']
  5. fopen should work with URL parameters. Give that a shot?
  6. From glancing over your code, it looks like you aren't supplying a valid password for the specified e-mail address. It is taking the e-mail address and looking for a record that matches has the specified e-mail address and a password value that matches a digest of your posted password. This doesn't appear to be a PHP error. It just looks like you're using the wrong e-mail/password combination.
  7. You asked a mouthful there. I'm assuming you're talking about client to server, instead of server to server. Without going into detail, you should check out AJAX. Here's an introductory tutorial: http://www.w3schools.com/Ajax/Default.Asp
  8. I'm assuming that's sanitized and you aren't posting the true code. That makes it a little more difficult to diagnose, because the values you're passing could be causing an issue. The site that you're posting to could be returning data that's causing the problem. Nothing is jumping out at me, with the code you posted. Can you post the real code?
  9. You shouldn't have the semicolon after your foreach. Also, you need a break. $Target="3.com"; $arr=array("http://1.com","http://2.com","http://www.3.com/whatever","http://4.com"); foreach($arr as $key => $value) { if(stristr($value, $Target)) { $Position = $key; break; } else $Position = "Not Found"; } print $Position;
  10. If WEB_ROOT contains "project8," then you should be using absolute paths, not relative. Ex: <a href="/<?php echo WEB_ROOT; ?>/admin/" class="leftnav">Home</a>
  11. fr34k

    Please Help

    $hold should be pointing to a resource returned from mysql_connect. If there was an error when establishing that connection, then $hold would hold a value of false, which isn't a valid MySQL connection.
  12. Can you post the exact error and code associated with the line(s)?
  13. The site that is infected, is it a publicly available script? Can you provide a name of the PHP application? I ask because if it got in through some exploit in your scripts, then cleaning it is kind of fruitless. It'll likely be back, very soon. If you can upgrade or patch the PHP application, it might prevent re-infection (and in the upgrade/patch process, might even overwrite the infected files.) It's very important to remove the origin of the infection, as quickly as possible.
  14. Try moving this to the top of your PHP page: <?php require_once("config.php"); ?> And put this in your advertisement areas: <?php $random = rand(0, count($image)-1); echo "<p><a href=\"" . $link[$random] . "\"><img src=\"" . $image[$random] . "\" border="0" /></a></p>"; unset($link[$random], $image[$random]); ?> I think that'll do it for you. It's not an optimal solution, but it's the easiest. By the way, there's tons of room for improvement here. You should look into associative arrays and the array_rand function.
  15. What isn't working, exactly? I'm assuming you just want to output a FLV, based on a parameter passed via URL. If that's the case: 1) Make sure that you're passing a valid value for "tv" in the URL (1-5.) 2) Is the document root correct? 3) Is "mysite.com/sorry.flv" for our benefit or is that actually in your code?
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.