Has anyone successfully automated sending neomail messages recently?
TNT really fucked with the code on that page, and even nearly 100% imitating a real message (using charles to verify) doesn't do the trick.
The only thing in the request I haven't gotten the same is the "Connection: keep-alive", since mechanize doesn't support it. I almost have gotten to the point of using a different module that will support it (even though it seems odd that this would cause the problem - or is it not odd?)
I should mention I'm not building any sort of spambot bs. I'm looking for easier ways to reply to messages using my own format is all.
I hadn't noticed the redirect- maybe I should take a look into that. I have no experience with keep-alive connections, so I was wondering if that was the issue. Last I checked I didn't see any other parts of the site that used this. All headers are the same as a legit request (except connection), however not in the same order lol...
I'm sending requests the same way I send almost all requests to neopets (which work for various parts of the site)- I'm not sure if thats what your wrapper comment is getting at?
My question in terms of using a wrapper - are you using the normal library functions of connecting to Neopets or are you using a class that handles all connections, cookies and such?
I know I'm not sending the neomail, I've check the recipient account, and the response is that angry red/white/black message saying "we don't know how you got here, check ur browser settings". So I'm sure it's what I'm sending.
Well I've manually added everything to the header so that it matches a legit neomail (I normally don't use all headers, but I added them all for this troublesome request) , and I have a library that handles cookies just fine everywhere else on neopets.
Thanks for your help, you've given me a few ideas to go off of. My login's messed up hehe, but it works- hasn't caused an icing ever since I've been using it- over a year now
hehe agreed, some of the code I wrote a year ago I cringe at, but it works... so as long as I don't need to touch it I'm revealed.
Works fine here ..
Based on the tamper data:
I made this script:
Notice this line?
html = acc.post("http://www.neopets.com/process_neomessages.phtml",postdata , "http://www.neopets.com/neomessages.phtml?type=send")
The last parameter is the refferal url (ie the page the browser was sent from) , without it we get this message:
Here is the received neomail....
I use neoaccount class by @ikakk
Last edited by DarkByte; 10-01-2013 at 03:45 AM.