Apr. 1st, 2004

wheee

Apr. 1st, 2004 01:01 am
ibneko: (Default)
Made massive changes to the bridge/proxy... Livejournal menu now shows up correctly, so you can SEE the links. There's also the options to flush your cookies that the "bridge" uses as well as the random cookie file that is created.

I still need to check and see why some of these images aren't showing up, but that's moderately minor.

The URL encoding method has been completely changed, after I did some more reading on the Crypt::CBC perl module. Although I think it might be pointless and unnecessary, since I _think_ the proxy server doesn't check the actual url request.... just the hosts and such. But still, to stay on the safe side, we'll use Crypt::CBC to encode your URL request.

Of course, disabling the encryption might mean more compatableness and stuff... I dunno, it's something I have yet to try and or even think about it.

I think I'll go to bed now... most of my 5 hours at home today were spent in front of the computer, alternatively programming Java (class project :P stupid stuff, although I'm still having random bugs. ::resists the temptation to look at Han's working(?) code) and perl (this thing)

Oh, yes, I've reached the point where I need people to go try out the bridge/proxy thing and tell me as they come across bugs. Bug reporting should include the page you were trying to get to, the page you were trying to get from, and the bug description (like, does it show a blank page? are images missing?). Obviously, it'd be best if you could include the original source code of the page and then the source code of the previous page before you hit the bug... then I could check the links and see where it messed up. 'course, if you don't know how to do that, don't worry too much. A simple ("I was trying to get here from this page." with links for "here" and "this" would be enough for me to work from.)

---
Drama...
Productive, wheee. Pervertedness too. Our little techies are picking up the pervertedness rather quickly ::proud::

The gurney (sp?too lazy to check) is almost complete. Just need to screw in the middle wheel. You know, it's going to look ugly, but I assume Mrs. Krebs can work with throwing a cloth over it. Hm, or they can spray-paint all but the supports silver. Then the rest can be painted black, so you don't see the center bar that's supporting the thing.

It's nice working with power tools... there's things I hadn't known about before and, well, spiffy tools. It's a nice change from doing lighting. Besides, we're almost all done with lighting.. Lights have been hung, gelled, focused... Just need to train the spots and which ever few people are doing the board... I wonder if I want to do board this time? I may just sit around and be lazy. Less stress and worrying of messing up that way.

---

Feh. Looks like I can't post using the proxy/bridge (I need a name for this thing!). Getting a [Error: Can't call method "clone" on unblessed reference at /Library/Perl/5.8.1/HTTP/Message.pm line 22. @ localhost] error. :P That's one I _don't_ know how to fix. Yet. the error is familiar though...

I lied.

Apr. 1st, 2004 01:33 am
ibneko: (Default)
I didn't go to bed. Instead, I messed with the code some more. POST (the http request type) works now, which means everything else should work, including stupid websites that require that your requests be refered from their site.

Okey~

Apr. 1st, 2004 10:22 pm
ibneko: (Default)
Userpics should now show up..? or some of them, anyways... livejournal doesn't include the .jpg or .gif extensions, which I depend on to figure out if I should search it for html links or not. I've included a checking thing to test for jpeg/gif ("GIF" or "JFIF" in the files.. Jpeg has other identification things inside it that I should be able to search for, as well, I believe...)

This fixes 90% of the userpics... However, the private "locked" icon denoting a locked post doesn't show up, even though it's being sent as it was received. Foo. This probably means there's something else wrong all together, which I haven't been able to notice or figure out. That can wait until tomorrow or spring break or something, There's rehearsal tomorrow, I'm tired and I'm going to bed after a shower.

Hm, and occasionally, cookies don't get sent* when using the POST http request method (the default method is the GET method, but good sites that send important data and/or forms tend to use POST.. this applies to livejournal... all login, comments, updates are all done using POST, since it's more "secure" that way, in that your data doesn't get saved in the history†....)

*Yeah, anyone know to how append HTTP::Cookie to the LWP::Agent->request()?
=>$HTTPagent is an instance of LWP::Agent
=>/%POST is the POST data... including the cookies in there doesn't seem to do any good... cookies need to go the the header of the http request and apparently that isn't how it works...

#The below half-works for other POST request based sites, but breaks livejournal...
#my $header = HTTP::Headers->new(referer => $refurl);
#my $request = HTTP::Request->new(POST => $url, $header, $data);
#my $cookie_jar = HTTP::Cookies->new(file => "$cookie.txt");
#$cookie_jar->add_cookie_header($request);
#$replyhash = $HTTPagent->request($request);

#This works for livejournal but doesn't always include the cookies.
$HTTPagent->cookie_jar(HTTP::Cookies->new(file => "$cookie.txt", autosave => 1));
$replyhash = $HTTPagent->request(POST $url, \%POST);

†Tech details:
In a GET request, your data is appended to the actual URL. So you'll see something like http://www.livejournal.com/login.bml?user=ibneko&password=kitty - this means the entire thing, including the user= and password= are saved into your history, cache, etc.
Whereas, in a POST request, your data is included after the http request. So only http://www.livejournal.com/login.bml gets saved.
There's probably other reasons, but those are the ones that come to mind right now. Besides, POSTs look neater overall.

Expand Cut Tags

No cut tags

Profile

ibneko: (Default)
ibneko

Most Popular Tags

Page Summary

Style Credit

Page generated Jul. 5th, 2025 05:40 am
Powered by Dreamwidth Studios
January 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 2021