--- Log opened Sun Jan 29 00:00:46 2012 |
00:12 | | Kindamoody [Kindamoody@Nightstar-3ef7401e.netlogon.liu.se] has quit [[NS] Quit: going home!] |
00:33 | | Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has quit [Ping timeout: 121 seconds] |
00:35 | | Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has joined #code |
00:48 | | Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has quit [Ping timeout: 121 seconds] |
00:50 | | Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has joined #code |
01:02 | | Kindamoody|out [Kindamoody@Nightstar-5507a6b5.tbcn.telia.com] has joined #code |
01:02 | | mode/#code [+o Kindamoody|out] by ChanServ |
01:03 | | Kindamoody|out is now known as Kindamoody |
01:22 | | Kindamoody is now known as Kindamoody[zZz] |
01:55 | | Derakon is now known as Derakon[shower] |
02:19 | | Derakon[shower] is now known as Derakon |
03:08 | | Derakon is now known as Derakon[AC2] |
03:12 | <@ToxicFrog> | Oh god wha |
03:12 | <@ToxicFrog> | function safe_query($query){ |
03:12 | <@ToxicFrog> | if(strpos(getcwd(),'admin')){ |
03:12 | <@ToxicFrog> | shell_exec("echo '".date("Y-m-d H:i:s")."|".$query."' >> |
03:12 | <@ToxicFrog> | /var/sql_logs/".str_replace("www.","",$_SERVER['HTTP_HOST']."")); |
03:12 | <@ToxicFrog> | } |
03:29 | <@ToxicFrog> | and then it just does |
03:29 | <@ToxicFrog> | $result = mysql_query($query); |
03:29 | <@ToxicFrog> | So this is a "safe_query" that passes unsanitized user input to both mysql_query() and shell_exec() |
03:33 | <@ToxicFrog> | Oh, and here's an uploadify.php that is actually 75% validation code to make sure the user isn't doing anything tricky with .. or / or file extensions |
03:33 | <@ToxicFrog> | Pity all of that validation code is commented out |
03:35 | | Attilla [Obsolete@Nightstar-1b32260b.as43234.net] has quit [Ping timeout: 121 seconds] |
03:38 | <@cpux> | I suggest kicking the compiler in the nuts. |
03:44 | <@ToxicFrog> | Anonymous already did; this is from the postmortem on the massive hacking of US law enforcement servers last summer. |
03:45 | | Derakon[AC2] is now known as Derakon |
03:50 | <&Derakon> | I never understand why people assume this has never been dealt with before and made into a rigorously-tested set of secure functions for their language of choice. |
03:53 | <@ToxicFrog> | Well, if you're using PHP, it hasn't been~ |
04:18 | | Vash [Vash@Nightstar-8697fea9.wlfrct.sbcglobal.net] has quit [[NS] Quit: I lovecraft Vorn!] |
05:05 | | Janus [NSwebIRC@Nightstar-27138e8c.res.rr.com] has joined #code |
05:17 | < Janus> | May I ask a small question in the form of a picture? |
05:19 | < Janus> | I should have asked that in picture form too. Whoops! http://dl.dropbox.com/u/3108480/whatamieven027.png I wanna do a thing that looks like this, but I don't know what that would be called. |
05:20 | <&Derakon> | Well, first off the "math things" are edges. :) |
05:21 | <&Derakon> | So you have a graph and you want to be able to grab nodes on the graph and drag them around, but after you let go of them they slowly move back to...what? |
05:22 | <&Derakon> | Their original location? A position as defined by their neighbors? |
05:23 | < Janus> | Um, I suppose the original location! ... or maybe the neighbor. I'm not sure which would work best yet. I wanna do 2D fabric soft simulation stuff with it. |
05:25 | <&Derakon> | I really suggest then that you look up fabric algorithms. |
05:25 | < Janus> | Nothing fancy or even robust. Just something to help me animate certain things on sprites, like dresses and hair. It'd only have to respond to wind, movement, and whatever bodyparts they are attached to |
05:25 | <&Derakon> | I mean, you can try to figure out something on your own that might kinda work, but people've been working on this stuff for decades now. |
05:26 | <&Derakon> | Ah. |
05:26 | < Janus> | Oh, they have? I only ever found stuff for 3D. I can try looking harder, aha. I was gonna do just that once I figured out what the right words to search with were |
05:26 | <&Derakon> | I wouldn't be surprised if you could omit a dimension without loss of utility. |
05:31 | <@ToxicFrog> | Also, the singular of "vertices" is "vertex" |
05:33 | < Janus> | ... whoops! I didn't know that. |
05:35 | <@ToxicFrog> | You might be able to do something using joints and forces in box2d, but there's probably one or more specialized libraries for this somewhere. |
05:35 | <@ToxicFrog> | (although if you're using box2d anyways...) |
05:40 | < Janus> | Oh I'm using it! I don't know if it'd work very well though. The fabric thing would be for very small sections on small sprites, and I've had box2D flip out when I go overboard with joints, aha. 6 wheel joints I have discovered is the hard limit |
05:41 | < Janus> | Well, not hard. But stuff starts fibrating violently, then rocketing towards the sky like a glitchy tiger in skyrim |
05:49 | < Janus> | Like the faulds on this sprite. http://dl.dropbox.com/u/3108480/10percentdonebleh.png It'd only need to be one solid colour, so long as it didn't let the legs clip through. |
05:51 | | * Janus would have to turn the resulting shape through something to make the sillouette appealing anyway |
06:01 | <&Derakon> | Honestly it seems to me like it'd be easier to just hand-animate the cloth. |
06:02 | | * Janus is pointed to he wikipedia article on Verlet Integration. Fragments of his head are found across the countryside. |
06:06 | < Janus> | I'm starting to think that too, sadly. Hair and cloth are ginourmous pains to animate though. Takes me about 2 hours to do just 5 or 6 frames. For small things! Large things like those faulds, or really long hair, take much longer, and need twice as many frames. Not because there's a lot of work perse. Just a lot of tuning and retuning |
06:07 | | eckse [eckse@Nightstar-6eec2b93.dsl.sentex.ca] has quit [Client closed the connection] |
06:20 | | celticminstrel [celticminst@Nightstar-5d22ab1d.cable.rogers.com] has quit [[NS] Quit: And lo! The computer falls into a deep sleep, to awake again some other day!] |
06:21 | | Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has quit [Ping timeout: 121 seconds] |
06:35 | | Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has joined #code |
06:35 | | Stalker [Z@2C3C9C.B2A300.F245DE.859909] has quit [Ping timeout: 121 seconds] |
06:39 | | Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has quit [Ping timeout: 121 seconds] |
06:41 | | Eri [Eri@Nightstar-3e5deec3.gv.shawcable.net] has quit [Ping timeout: 121 seconds] |
06:45 | | Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has joined #code |
06:46 | | Derakon is now known as Derakon[AFK] |
06:49 | | Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has quit [Ping timeout: 121 seconds] |
06:51 | | Janus [NSwebIRC@Nightstar-27138e8c.res.rr.com] has quit [[NS] Quit: zzzzz] |
06:56 | | AnnoDomini [annodomini@Nightstar-f7eedefa.80-203-17.nextgentel.com] has joined #code |
06:56 | | mode/#code [+o AnnoDomini] by ChanServ |
06:56 | | Eri [Eri@Nightstar-3e5deec3.gv.shawcable.net] has joined #code |
07:40 | | Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has joined #code |
07:40 | | Kindamoody[zZz] is now known as Kindamoody |
08:07 | | Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has quit [Ping timeout: 121 seconds] |
08:10 | | Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has joined #code |
08:14 | | Stalker [Z@Nightstar-3602cf5a.cust.comxnet.dk] has joined #code |
08:37 | | Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has quit [Ping timeout: 121 seconds] |
09:06 | | AnnoDomini [annodomini@Nightstar-f7eedefa.80-203-17.nextgentel.com] has quit [[NS] Quit: Time to get going.] |
09:21 | | Kindamoody is now known as Kindamoody|out |
10:26 | | Kindamoody|out [Kindamoody@Nightstar-5507a6b5.tbcn.telia.com] has quit [Client exited] |
10:55 | | Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has joined #code |
11:28 | | Kindamoody|out [Kindamoody@Nightstar-3ef7401e.netlogon.liu.se] has joined #code |
11:28 | | mode/#code [+o Kindamoody|out] by ChanServ |
11:32 | | Kindamoody|out is now known as Kindamoody |
11:38 | | * TheWatcher vaguely pokes the channel, wonders if there's anyone in here has ever attempted to hook irssi's logging up to a database |
11:40 | <@Tamber> | Not I, sorry. |
11:40 | <@Tamber> | ...although it does sound rather handy. *ponders* |
11:40 | <@Tamber> | (But my list of things to do /really/ doesn't need any more adding to it~) |
11:41 | <@TheWatcher> | Yeah, well, I am asking because I'm investigating how possible it is |
11:42 | <@TheWatcher> | aha |
11:42 | <@TheWatcher> | someone's already done it, or something close enough |
11:43 | <@TheWatcher> | ... oh dear sweet zombie jesus, he's opening and closing the database connection for each log operation, what |
11:44 | <@Ling> | If there's one thing I've learned, it's that programmers haven't a fucking clue how a DB works. |
11:44 | <@Ling> | So few are the gems that are the exceptions. |
11:47 | <@TheWatcher> | WOrse, he's loaded DBI, and is constructing SQL queries by hand, no prepare(), doing on validation on the messages, and he's talking to DBD::mysql directly. I whish I knew where this guy hung out, this thing is a big, flashing "Please screw with my database!" invitation |
11:50 | | * TheWatcher knucklecracks |
11:50 | | * Tamber hands TW a golf-bat. |
11:52 | | * TheWatcher beats this guy with it first, then uses him to beat whoever wrote the irssi script intrface docs |
12:06 | | Attilla [Obsolete@Nightstar-1b32260b.as43234.net] has joined #code |
12:10 | | * TheWatcher eyes |
12:13 | <@TheWatcher> | Apparently you can add an unload handler to irssi scripts. They just don't document that, anywhere. |
12:14 | <@TheWatcher> | d |
12:14 | <@Tamber> | Naturally. |
12:18 | <@TheWatcher> | (you can't use END { } blocks, as it simply nukes the package symbol table and frees the memory >.< - you need to implement 'sub can { my $self = shift; my $op = shift; return $op eq "UNLOAD"; } sub UNLOAD { ... } as far as I can tell) |
12:19 | <@TheWatcher> | Yep, that's the trick |
12:20 | <@TheWatcher> | SO, I should be able to persist database connections, anyway |
12:24 | <@TheWatcher> | of course, there's the "what if the db goes away" issue. I guess this needs to be done in addition to text logging, and I'll need to write something to fix up missing data from them (which I'll need anyway to import all my old logs) |
12:27 | | Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has quit [Client exited] |
13:05 | | ToxicFrog [ToxicFrog@ServerAdministrator.Nightstar.Net] has quit [Operation timed out] |
13:12 | | ToxicFrog [ToxicFrog@ServerAdministrator.Nightstar.Net] has joined #code |
13:12 | | mode/#code [+o ToxicFrog] by ChanServ |
13:13 | | Irssi: #code: Total of 27 nicks [22 ops, 0 halfops, 0 voices, 5 normal] |
13:19 | | Vash [Vash@Nightstar-8697fea9.wlfrct.sbcglobal.net] has joined #code |
13:19 | | mode/#code [+o Vash] by ChanServ |
13:20 | | * TheWatcher vaguely wonders if there's more undocumented aspects of irssi's perl interface than there are documented. |
14:03 | | * TheWatcher eughs at this old code |
14:04 | <@TheWatcher> | What in the name of Nyarlahotep's striped pajamas was I bloody thinking? |
14:05 | <~Vornicus> | For the record |
14:05 | <~Vornicus> | Polka dot, not striped. |
14:06 | <@TheWatcher> | Fair enough, you'd know better than me. |
14:07 | <@TheWatcher> | I just make frightful incantations to the Outer Gods, after all. |
14:52 | | Kindamoody is now known as Kindamoody|afk |
15:40 | | Kindamoody|afk is now known as Kindamoody|out |
15:50 | | Vash [Vash@Nightstar-8697fea9.wlfrct.sbcglobal.net] has quit [[NS] Quit: I lovecraft Vorn!] |
15:57 | | Kindamoody|out [Kindamoody@Nightstar-3ef7401e.netlogon.liu.se] has quit [Client exited] |
15:57 | | RichardBarrell [mycatverbs@Nightstar-906df3b3.bb.sky.com] has joined #code |
16:03 | | RichardBarrell [mycatverbs@Nightstar-906df3b3.bb.sky.com] has quit [Operation timed out] |
16:16 | | Derakon[AFK] is now known as Derakon |
16:38 | | Kindamoody|out [Kindamoody@Nightstar-5507a6b5.tbcn.telia.com] has joined #code |
16:38 | | mode/#code [+o Kindamoody|out] by ChanServ |
16:38 | | Kindamoody|out is now known as Kindamoody |
17:21 | | eckse [eckse@Nightstar-6eec2b93.dsl.sentex.ca] has joined #code |
17:23 | | celticminstrel [celticminst@Nightstar-5d22ab1d.cable.rogers.com] has joined #code |
17:32 | | Stalker [Z@Nightstar-3602cf5a.cust.comxnet.dk] has quit [[NS] Quit: Connection reset by bears] |
17:36 | | eckse [eckse@Nightstar-6eec2b93.dsl.sentex.ca] has quit [Killed (Services.Nightstar.Net (Too many invalid passwords))] |
17:36 | | eckse [eckse@Nightstar-6eec2b93.dsl.sentex.ca] has joined #code |
17:46 | | cpux [cpux@Nightstar-c5874a39.dyn.optonline.net] has quit [Ping timeout: 121 seconds] |
17:48 | | * TheWatcher fiddles with message signals, bleghs at the 'documentation' again |
18:00 | | * TheWatcher eyes mysql |
18:02 | <@TheWatcher> | "A DATETIME or TIMESTAMP value can include a trailing fractional seconds part in up to microseconds (6 digits) precision. Although this fractional part is recognized, it is discarded." |
18:03 | <@TheWatcher> | I.. what. Why bother saying it is 'recognised' if you're jut throwing the damned thing way. |
18:03 | < gnolam> | "I see what you did there" |
18:03 | <&Derakon> | It won't cause parse errors? |
18:05 | <@TheWatcher> | Dera: why not just straight up say "any fractional seconds part is discarded" then? |
18:06 | <@TheWatcher> | Meh. Anyway |
18:54 | | Kindamoody is now known as Kindamoody[zZz] |
19:16 | | Jester [tehjester@8E7DA3.3BA2F6.D68D1A.03BFBB] has joined #code |
21:11 | | Jester [tehjester@8E7DA3.3BA2F6.D68D1A.03BFBB] has quit [[NS] Quit: ] |
21:57 | < maoranma> | Oh noes, my nicklist is black with idlers! |
21:57 | <@jerith> | maoranma: Like me? |
21:58 | < maoranma> | Not anymore :) |
21:58 | < maoranma> | I setup mIRC a while ago to make nicks that are idle for hours to turn the same color as the background, and others change to various shades from green to red |
21:59 | <@Ling> | Red meaning our silence kills us? |
21:59 | < maoranma> | And I made a script that when someone talks and they aren't assigned a color in my address book for messages, it randomly assigned one that isn't white or black |
21:59 | <@Ling> | I like the idler script though, that sounds cool |
22:01 | < maoranma> | it's not a script, just a function of the mIRC nicklist, because it maintains the IAL better than I could emulate with a script. I'm sure there's an elegant way to make it a script, but meh. I could write an alias that does the necessary nicklist changes one time though |
22:01 | <@jerith> | Angry fruit salad! |
22:01 | | * TheWatcher eyes the DBI documentation |
22:02 | <@TheWatcher> | I'm really glad I seldom need to go beyond the core bits of this |
22:02 | <@jerith> | Databases make me sad. |
22:03 | <@jerith> | But now I'm sleepy. |
22:03 | <@jerith> | 'Night all. |
22:03 | <@TheWatcher> | Slepwell. |
22:03 | < maoranma> | White 0-5, green 5-14, yellow 15-29, orange 30-59, red 60-119, 120+ black |
22:03 | < maoranma> | In minutes |
22:04 | < maoranma> | on ^*:TEXT:*:*:{ |
22:04 | < maoranma> | if $cnick($nick) = 0 { |
22:04 | < maoranma> | cnick -m1 $nick $rand(2,15) |
22:04 | < maoranma> | } |
22:04 | < maoranma> | } |
22:04 | < maoranma> | that's the script for a random color on message |
22:05 | < maoranma> | I could base it on host, so nick changes share the same color, and probably take less space too, I might do that later |
22:10 | < Eri> | I've done something similar, once |
22:11 | < Eri> | Not the colours, but tracking nick-changes based on host |
22:11 | < Eri> | It sort of works |
22:11 | <@Ling> | It's fun when people cloak/decloak on Unreal networks |
22:11 | < maoranma> | Hehe |
22:11 | < Eri> | Eventually I ended up with, like, a 25 MB file with a poopload of hostmasks |
22:11 | | himi [fow035@Nightstar-5d05bada.internode.on.net] has quit [Ping timeout: 121 seconds] |
22:12 | < Eri> | Probably should have implemented some kind of fuzzy match, so small changes in hostmasks over multiple logins would hopefully be reconciled to the same user |
22:13 | < maoranma> | Well, there are some mask types in mirc, so something like *!ident@*.domain.com |
22:13 | < maoranma> | So similar idents and domains get consolidated |
22:14 | < Eri> | Hmm. Yeah, I hadn't used idents, just hosts |
22:15 | < Eri> | It was something I whipped up at, like, fifteen, as a little project to learn mIRC's scripting language |
22:15 | < maoranma> | Yea, $mask(X,3) *!*user@*.host |
22:15 | < maoranma> | So if you get idents like ~dude or just dude, it still matches |
22:16 | < maoranma> | Yea, /help topic is my friend |
22:16 | < Eri> | You know what's sad? TI-BASIC and mIRC script were my first steps into programming. |
22:16 | < Eri> | Probably the worst intro ever. Both of them made me want to pull my hair out. |
22:16 | <@Tamber> | Locomotive BASIC is what got me interested in programming. |
22:16 | <@Tamber> | ...I'm fairly sure there's remnants of it that have stuck, unfortunately :) |
22:16 | | mode/#code [+oooooo Attilla Eri eckse celticminstrel maoranma gnolam] by Tamber |
22:17 | <@Eri> | Heh |
22:17 | <@maoranma> | I leared BASIC on a Tandy |
22:17 | <@Eri> | Even now, sometimes I think back to TI-Basic, and wish I could use a goto. |
22:18 | <@Eri> | Then I feel bad about myself, and realize that's the dumbest solution ever |
22:18 | <@Tamber> | Pft. |
22:18 | <@maoranma> | So when I figured out my TI did basic, I almost got kicked out of math |
22:18 | <@Eri> | XD |
22:18 | <@Tamber> | There's a time and a place for goto. |
22:18 | <@maoranma> | Looping? |
22:19 | <@maoranma> | Seems like I could look on the TI some other way |
22:19 | <@Eri> | I had a really crappy implementation of all the trigonometric laws. I could dump in whatever information I had on a triangle, and it would poop out everything else. Worked really well until the final, when they took the calculator away |
22:19 | <@maoranma> | loop* |
22:19 | <@Tamber> | maoranma, Only if you're breaking out of one to error at a common point. |
22:20 | <@maoranma> | I haven't used BASIC syntax since highschool, so :\ |
22:20 | <@Tamber> | (Or, y'know, you haven't got looping constructs that deal with that.) |
22:20 | <@Tamber> | ...ah, I wasn't talking about BASIC, in this case. :) |
22:21 | <@maoranma> | I almost started to teach myself Z80 assembly too, but my now wife/then ex-girlfriend stole my frakking calculator |
22:21 | <@Tamber> | I /think/ Locomotive BASIC had FOR and WHILE. But GOTO was kinda handy sometimes. (GOSUB/RETURN saved what was left of my sanity quite a lot.) |
22:23 | | * TheWatcher ;.;, knows he's going to have to go look at the DBI source to find out whether there are actually any real situations where disconnect() will fail, as the docs are horribly ambiguous |
22:24 | <@Tamber> | (That smell is TheWatcher burning what few SAN points he has left...) |
22:25 | <@TheWatcher> | I've been reading irssi's source half the day. You think I have any left? |
22:25 | <@maoranma> | TI Basic has while/repeat and for apparently |
22:26 | <@Eri> | Yeah |
22:27 | <@Eri> | I think loops had a memory leak issue, if I recall |
22:27 | <@Eri> | I used to butt heads with it a lot. |
22:27 | <@maoranma> | Maybe, I think they fixed it though |
22:27 | <@maoranma> | I had the USB cable, so I was able to update it |
22:27 | <@Eri> | Yeah, same. I think the problem was actually in making goto loops, now that I recall |
22:28 | <@Eri> | That was from before I knew what flow control was |
22:28 | <@maoranma> | A myth? |
22:29 | <@maoranma> | I miss my TI-83+ SE |
22:30 | <@maoranma> | You had to use assembly to access greater than 24k of the ram though |
22:32 | <@TheWatcher> | Well, DBI::mysql at least always returns true, so sod it. |
22:32 | <@TheWatcher> | *DBD |
22:33 | | Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has joined #code |
22:34 | <@Eri> | Alberta high speed internet access? Why did I never notice that? We could have been friends, but then I moved |
22:35 | <@maoranma> | Because of lack of high speed access? |
22:42 | <@Ling> | St Albert, oh yeah! |
22:43 | <@Eri> | Pretty much |
22:43 | <@Eri> | Actually, I was, like, an hour from Nordegg, so my internet was through an overused radio relay tower |
22:44 | <@Eri> | Might as well not even have had internets |
22:53 | <@maoranma> | Wow, you can get internet that way? |
22:57 | <@Eri> | Sort of, yeah. Radio relay to a satellite. |
22:57 | <@Eri> | In theory, you could do purely terrestrial radio relay |
22:57 | <@Eri> | In practice, it sucks serious ass |
23:24 | | himi [fow035@D741F1.243F35.CADC30.81D435] has joined #code |
23:24 | | mode/#code [+o himi] by ChanServ |
23:49 | <@TheWatcher> | Hrm, can someone say something, I need to check if I'm inserting these signals right... |
23:50 | <@ToxicFrog> | Mrr? |
23:51 | <@TheWatcher> | Well, blegh, it looks like the nick data sent to 'message public' doesn't include op status, hohum, I can pull it out of the channel I guess |
23:51 | <@TheWatcher> | Thanks anyway |
23:52 | <@ToxicFrog> | It doesn't? |
23:52 | <@ToxicFrog> | Say something. |
23:52 | <@TheWatcher> | Something. |
23:53 | <@ToxicFrog> | Oh, so it doesn't. |
23:54 | <@TheWatcher> | $server -> find_channel($target) -> nick_find($nick) -> {prefixes} should be enough (or op/halfop/etc in the Nick object) |
23:55 | <@TheWatcher> | *channel_find |
23:59 | <@TheWatcher> | Yep, that does what I need, excellent. |
--- Log closed Mon Jan 30 00:00:03 2012 |