Sunday, 2009-12-20

../irclogs/#mantishelp.2009-12-20.log
--- scribe started ---00:00
paul__dhx_m / nuclear_eclipse : *SIGH*00:15
paul__dhx_m: up still?09:35
* paul__ wonders how one gets 1.2master branch10:01
dhx_mpaul__: hey10:36
dhx_mpaul__: git checkout master-1.2.x10:37
paul__$ git checkout master-1.2.x11:15
paul__error: pathspec 'master-1.2.x' did not match any file(s) known to git.11:15
dhx_moh11:25
dhx_myou need to add a new remote11:25
dhx_mhmmm actually no you don't...11:25
dhx_mdoes master-1.2.x show in git branch -a11:26
dhx_mgit branch --help11:26
dhx_moops11:26
paul__yea11:26
paul__remotes/orogin/master11:27
dhx_mtry git checkout origin/master-1.2.x11:28
dhx_m?11:28
paul__gives a warning about it's not a local branch11:28
paul__but I guess it changes?11:28
dhx_moops11:29
dhx_mtry:11:29
paul__it's changed11:29
dhx_mgit checkout --track -b master-1.2.x origin/master-1.2.x11:29
paul__so I guess I can work on it?11:29
dhx_mthat will create a local tracking branch with the same name11:29
dhx_mnormally you'd want to stage commits in a local branch11:30
paul__now do we want 1.2 to be 5.09 or 5.10?11:30
dhx_mand then check them, and "git push origin master master-1.2.x" to make the changes go live11:30
dhx_msame as 1.3.x I'd argue11:30
paul__master master?11:30
dhx_mour dependencies should always be the latest stable version so we're up to date with security fixes, etc11:31
dhx_mnah... git push origin {branch1} {branch2} ... {branchX}11:31
paul__why would I want to push to master?11:31
dhx_myou can push multiple branches at once to the remote (in this case 'origin')11:31
dhx_mif you make changes to your local master (1.3.x) branch11:32
paul__then i'd just push to master11:32
paul__$ git cherry-pick 69aa96a3a347e80e3ddf3b2f5692c178bbdf6e3111:33
paul__Automatic cherry-pick failed.  After resolving the conflicts,11:33
paul__mark the corrected paths with 'git add <paths>' or 'git rm <paths>' and commit the result.11:33
paul__When commiting, use the option '-c 69aa96a' to retain authorship and message.11:33
paul__mmmmmm11:33
dhx_mwhat are you cherry-picking?11:33
dhx_moh11:33
dhx_mit's better to revert my commit11:33
dhx_mdelete the entire library/ directory11:34
paul__I did11:34
dhx_mthen copy the one from 1.3.x11:34
paul__hmm11:34
dhx_mand just make an overall "sync" commit11:34
dhx_mezC is also behind times in the 1.2.x branch11:34
paul__yea I know11:34
paul__i've updated it locally11:34
paul__I think we should put jquery into library dir too at some point11:34
paul__and start using it11:34
dhx_mI think it'd just be better if 1.2.x and 1.3.x library/ directories were 1:1 copies11:35
dhx_munless of course we add more dependencies in 1.3.x or later versions11:35
dhx_mor we use a development version of a library in 1.3.x but not 1.2.x11:35
paul__what i'm not happy with atm11:36
paul__is we've added shit since rc1/rc2 to 1.211:36
paul__that I think we should pull out11:36
paul__in trunk11:36
dhx_mexamples?11:36
paul__obvious example:11:36
paul__ldap api now stores md5 hash of password in mantis table11:37
paul__I've asked 3 friends from elsewhere so far11:37
dhx_mwhat's the point in storing md5 hashes? they can be cracked in no time at all11:37
paul__who have all gone 'wtf'11:37
paul__Personally11:37
paul__i'll be pulling that code out from my work version of ldap api11:37
dhx_mwhy are there hashes of passwords stored in Mantis at all?11:38
paul__er?11:38
paul__so you can log in ? :P11:38
dhx_misn't the whole idea of LDAP that you authenticate users via LDAP (hence passwords aren't stored in the Mantis DB)?11:38
paul__one friends comment:11:38
paul__'well, personally i'd try to avoid any redundancy, if someone wants ldap, let them use it and if ldap is important enough they'll make sure it's redundant anyway11:39
paul__in a windows world11:39
paul__(where I expect most people would probably find ldap these days ? (aka AD)11:39
dhx_myou've confused me so much now... what has redundancy got to do with password hashing?11:39
paul__i.e. storing ldap password is redundancy you'd want to avoid11:39
dhx_mis the idea in Mantis that if LDAP goes offline, you can use locally cached passwords in the DB for authentication?11:39
paul__I think so ;p11:40
dhx_mif that's the case then *ugh*11:40
dhx_mI just don't see why we should be storing duplicate information of data that is normally pulled from LDAP11:41
paul__the simulation stuff that's been added to 'simulate ldap from a text file' is making it more difficult for me to merge in my work changes11:41
paul__so for work11:41
paul__i'm gonna code a new ldap api I think11:41
dhx_munless LDAP queries are many times more expensive than SQL queries?11:41
paul__as i cba fixing my changes into our current ldap api11:41
dhx_mit requires a lot of planning though11:42
dhx_mbasically a new authentication API11:42
dhx_mthat can allow for plugins to provide external data11:42
paul__well11:44
paul__the new ldap stuff we now have kicks off more quieries then the old stuff11:44
paul__it's a mess ;/11:44
paul__the password duplication stuff was added in july 200911:45
paul__no sorry11:45
paul__October 200911:45
paul__Tue, 6 Oct 2009 - Updated release notes for RC211:46
paul__2009-10-2611:46
paul__it's a POST-RC2 change11:46
* paul__ checks whether it has been ported to master-1.211:46
paul__it's a post rc2 change11:47
paul__that has been ported to master 1.211:47
paul__that I want to get rid of in 1.3/trunk asap11:47
dhx_mcheck with whoever committed it though11:48
dhx_mit might have been part of a larger plan11:48
dhx_mpaul__: http://git.mantisbt.org/?p=mantisbt.git;a=commit;h=a8f9af9c39ec5603cfd7787ff324f65a6c5466e011:49
dhx_mpaul__: did you read the commit message? it seems like a fairly compelling need to me, short of moving LDAP out into a separate plugin11:50
dhx_mpaul__: and then adding new events like user_get_realname, etc that the new LDAP plugin hooks11:50
paul__the idea of ldap is it's redundant...11:54
dhx_myes, but the commit isn't about providing redundancy11:54
paul__1. Locations that require retrieval of user realname don't have to know about LDAP.11:54
dhx_mit's about decoupling LDAP from the rest of the code (so user_api.php doesn't need to know about LDAP)11:54
paul__that's wrong though11:55
paul__the realname display function should check against ldap11:55
paul__so that changes are immediately picked up11:55
dhx_magreed11:55
paul__so therefore11:55
dhx_mbut it should really be done via a plugin hook IMO11:55
paul__there's no point to store it in db11:55
dhx_mthat way you can authenticate via whatever means you want11:55
paul__2. Database information will be kept up to date and hence we can fallback to the database.11:55
dhx_mPAM, LDAP, etc11:56
paul__you'd normally have >1  ldap server11:56
paul__by the time you try a connect to multiple servers11:56
paul__the fallback is gonna be slow11:56
paul__so it might be better to alert user if all servers are down11:56
dhx_mI agree on (2)11:56
paul__i.e. 3 servers11:56
paul__10 seconds to make a ldap query + allow to timeout11:56
paul__= 30 seconds11:56
paul__after 30 seconds if ldap hasn't responded, sure you could fallback to db11:57
dhx_mwhat about (3) though... are there performance considerations? I'd argue there wouldn't be in a well designed LDAP plugin (it caches values it pulls from the directory)?11:57
dhx_mI'd argue fallbacks are bad design11:57
dhx_mthe purpose of LDAP is to have a central store for authentication/account info11:57
dhx_mif it's down, then you can't be sure you've got the latest account information (which is updated by third parties external from Mantis)11:58
dhx_mtherefore it's safer to assume that all accounts have been disabled (ie. lockout Mantis until LDAP comes back online)11:58
paul__performance: well, I'm not sure we've had users report issues?11:59
paul__and I suspect that with AD (probably biggest ldap server?) there's enough queries being generated by logons/exchange etc12:00
paul__4. Less possibility for LDAP specific bugs.12:00
paul__and i'd say is invalid12:00
paul__if you've got one realname in ldap12:00
paul__+ a different one in mantis12:00
dhx_magreed on (4)12:00
paul__the idea is sensible12:01
paul__however like...12:01
paul__to access mantis @ work12:01
paul__from home12:01
paul__i'd need to log in via isa server12:01
dhx_mand with (3) I think we still need caching (don't hit LDAP every time we need the real name... only the first time for each PHP process)12:01
paul__which requires my user/pass to be sent to LDAP server12:01
paul__before I see mantis12:01
dhx_mhowever you're right that storing that information in an SQL database is not a good caching method12:02
paul__to an extent we hide realname12:02
dhx_mas you said, we now have two points of failure instead of one, and the sources can desync, etc12:02
paul__there's two bits of data:12:02
paul__a) username12:02
paul__b) userid12:02
paul__c) realname12:02
paul__d) email12:02
paul__for the most part email gets used in two places:12:02
paul__a) view user page12:02
paul__b) manage/*12:02
dhx_mcan't you store any data with LDAP?12:02
paul__c) email api for events12:02
dhx_mie. you can create your own fields?12:03
paul__yea12:03
paul__i'm talking about what mantis does atm12:03
paul__now ifyour sending an email to a user12:03
paul__you'd probably want to check ldap for latest email address12:03
paul__the *problem* one is probably12:03
paul__realname12:03
dhx_mis it easy for LDAP admins to add extra fields?12:03
paul__fairly i believe12:03
paul__i.e. if you display realname not user names12:03
paul__so it might be sensible to cache realname12:04
dhx_mah, does LDAP suck for lookups (ie. find all users with an email address matching %something.com and who are part of the 'reporters' group)?12:04
paul__however, i'd do it in a seperate table (i.e. as part of plugin)12:04
paul__we dont do those type's of queries12:04
dhx_mI imagine we do... for instance, generating an email list for notifying users of changes to a bug12:05
paul__we'd always go from the username12:05
dhx_mwe don't want to send off 500 queries to an LDAP server with each one asking for the email address of a single user12:05
dhx_mpaul__: ldap_search() in PHP handles these lookups anyway :)12:07
paul__?12:07
dhx_mpaul__: http://php.net/manual/en/function.ldap-search.php12:07
dhx_mpaul__: pulling information on multiple users at once from the LDAP tree12:07
paul__yea up to 100012:08
paul__at a time12:08
paul__iirc12:08
paul__dhx_m: ?22:53

Generated by irclog2html.py