» Site Navigation | | | » Advertisement | | | » Recent Threads | Redemption? Today 05:57 PM Today 06:01 PM 2 Replies, 3 Views | I'm back. Today 05:37 PM Today 06:01 PM 12 Replies, 13 Views | SSOTM... Yesterday 02:42 PM Today 05:55 PM 31 Replies, 32 Views | | | New New New Today 04:41 PM Today 05:55 PM 5 Replies, 6 Views | |  | |  | [need help] PM posting Curl |  |
02-17-2008, 05:59 PM
|
#1 (permalink)
| | Banned
bug14 is offline
Join Date: Oct 2007 Location: bugmenot.com Posts: 1,532 Rep Power: 0 | [need help] PM posting Curl Since the curl Alex showed me worked perfectly with my fake Gaia editing program. I decided to play around with curl and try to make something that actually isn't a scam for a change. I want to make a webpage that will post PMs on Gaia. Now before I go setting up the array of names and a timer to post a new PM every 30 seconds (that is the max amount of time allowed between PMs on Gaia, last time I checked), I want to see if it's even possible first. This is the script I set up in a file called pmer.php: PHP Code: //pm from here $postfields2 = "username=".$_POST['username']."&subject=".$_POST['subject']."&message=".$_POST['message']."&attach_sig=".$_POST['attach_sig'].'&post=&mode=post&src=&folder=inbox&id=';
$reffer2 = $data_url; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL,$pm_post_url); curl_setopt($ch, CURLOPT_USERAGENT, $agent); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, $postfields2); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1); curl_setopt($ch, CURLOPT_REFERER, $reffer2); curl_setopt($ch, CURLOPT_COOKIEFILE, $cookiefile); curl_setopt($ch, CURLOPT_COOKIEJAR, $cookiefile); $result = curl_exec ($ch); curl_close ($ch);
As you can tell by the title of my thread it's not working. Am I even going about this the right way? I don't need you to write the code for me, just point out my flaws with this and/or suggest a better way about going about it.
Last edited by bug14; 02-21-2008 at 11:56 AM.
| |
| |  |
02-17-2008, 07:29 PM
|
#2 (permalink)
|
Googlrr is online now Join Date: Oct 2006 Location: New Hampshire? Posts: 6,541 Rep Power: 16 | I'm not sure, but does it have something to do with the postdata not being encoded? o.o Like, if your input message included spaces and such, that wouldn't fly with the post data.
I'm not too good with cURL. Dx
__________________ 
Li-Shun is a god. ^ 
hatzganatta is awesome too ^^
| |
| |
02-18-2008, 03:37 PM
|
#3 (permalink)
| | Banned
bug14 is offline
Join Date: Oct 2007 Location: bugmenot.com Posts: 1,532 Rep Power: 0 | If I echo $result it shows Gaia, logged in, and and all the forms in the "Send a New PM" page are filled in with the variables(pm to, message, subject, etc) posted from my form, ready to be sent. I just don't know about posting it actually to gaia then because I don't know how to view the source of Gaia's privmsg.php. Do I need to str_replace "privmsg.php" with "http://www.gaiaonline.com/privmsg.php" or something?
EDIT: Am I missing a post field? | |
| |
02-18-2008, 05:09 PM
|
#4 (permalink)
|
Googlrr is online now Join Date: Oct 2006 Location: New Hampshire? Posts: 6,541 Rep Power: 16 | username=username&subject=lolcakes&addbbcode22=bla ck&addbbcode24=12&addbbcode26=left&helpbox=&messag e=lolcakes&preview=&post=true&mode=post&src=&folde r=inbox&id=&x=42&y=10
There's my postdata. I would say try to leave all of it in, just to ensure no error.
__________________ 
Li-Shun is a god. ^ 
hatzganatta is awesome too ^^
| |
| |
02-18-2008, 05:11 PM
|
#5 (permalink)
| | ♥ Homosexual Member ♥
masterjoe42 is offline
Join Date: Jan 2008 Location: Laughing Man Posts: 3,019 Rep Power: 0 | good luck, bug. | |
| |
02-18-2008, 07:31 PM
|
#6 (permalink)
| | Banned
bug14 is offline
Join Date: Oct 2007 Location: bugmenot.com Posts: 1,532 Rep Power: 0 | Quote:
Originally Posted by Googlrr username=username&subject=lolcakes&addbbcode22=bla ck&addbbcode24=12&addbbcode26=left&helpbox=&messag e=lolcakes&preview=&post=true&mode=post&src=&folde r=inbox&id=&x=42&y=10
There's my postdata. I would say try to leave all of it in, just to ensure no error. | It works, OMG! I LOVE YOU! IT WORKED! OH YEAH BABY! btw. How did you get that post data? My method was saving the pm page and then have it post it into a text file to see what it was. Mine was missing the bbcode things and had an extra attatch_sig thing in there. I bet that was screwing it up.
I FUCKING LOVE YOU! +Rep!
Last edited by bug14; 02-18-2008 at 07:34 PM.
| |
| |
02-18-2008, 07:34 PM
|
#7 (permalink)
| | ♥ Homosexual Member ♥
masterjoe42 is offline
Join Date: Jan 2008 Location: Laughing Man Posts: 3,019 Rep Power: 0 | . . .so this sends messages out to people. . .Can you decide what the message says? | |
| |
02-18-2008, 07:47 PM
|
#8 (permalink)
| | Banned
bug14 is offline
Join Date: Oct 2007 Location: bugmenot.com Posts: 1,532 Rep Power: 0 | Quote:
Originally Posted by masterjoe42 . . .so this sends messages out to people. . .Can you decide what the message says? | Yeah. I'm basically making this so I can PM all 72 members of the guild that I own without all the hard work of manully doing it. I want to see if they will rally behind me in the petitions forum and get me unbanned (at least a temp unban so I can hand ownership over to my crew). I will release it here (when I'm done), if I can get Alex's permission. I can't PM him because his account is messed up here and I don't have a LG account. He already let me use this code once in my Gaia Editing program, but I should probably be certain. | |
| |
02-18-2008, 07:50 PM
|
#9 (permalink)
| | ♥ Homosexual Member ♥
masterjoe42 is offline
Join Date: Jan 2008 Location: Laughing Man Posts: 3,019 Rep Power: 0 | If Gaiaunline wasn't blocked, this would be beyond useful for sending the scam around to multiple people, making your job of getting the info on the accounts that much easier and that much faster. | |
| |
02-18-2008, 07:52 PM
|
#10 (permalink)
| | Banned
bug14 is offline
Join Date: Oct 2007 Location: bugmenot.com Posts: 1,532 Rep Power: 0 | Quote:
Originally Posted by masterjoe42 If Gaiaunline wasn't blocked, this would be beyond useful for sending the scam around to multiple people, making your job of getting the info on the accounts that much easier and that much faster. | Yeah, scams makes it all the more worth releasing. And there is still Kyo's domain. | |
| |  | | |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | | | | Thread Tools | | | | Display Modes | Linear Mode |
Posting Rules
| You may not post new threads You may not post replies You may not post attachments You may not edit your posts HTML code is Off | | | |