Martin Paljak <mar...@martinpaljak.net> a écrit sur 20/01/2011 13:40:02 :
> [image supprimée] > > Re: [opensc-devel] Proposed cardmod patch > > Martin Paljak > > A : > > francois.leblanc > > 20/01/2011 13:42 > > Cc : > > "Douglas E. Engert", OpenSC-devel, Brian Thomas > > Hello, > > On Jan 20, 2011, at 11:28 AM, francois.lebl...@cev-sa.com wrote: > > "Douglas E. Engert" <deeng...@anl.gov> a écrit sur 20/01/2011 00:46:51 : > > > > It's close to the first release I've develop see the start > > > > http://www.opensc-project.org/pipermail/opensc-devel/2009-October/ > 012610.html > > > > but Martin at this time was not hot to introduce such extra configuration > > on > Sorry, I don't know what "extra configuration" you are talking about.. It's bad translation of what I want to say, I talk about pcsc context and handle in parameters structure. As far as remember you discouraged to introduce too much modification in opensc code (and It's ok for me) and to limit the impact the prefered way to transmit this parameters are to use variables environment or key register. > > > context params structure. Martin provide another links to patch > > introducing > > > > solution using key register... > > I provided a link to an alternative solution (using environment > variables and proper modifications for PC/SC driver to behave > accordingly, not copying of the code) with the hope of encouraging > you to investigate your solution and think about possible > alternative approaches. Yes but remember, I've started to introduce parameters in structure to pass pcsc handle and context and when I proposed the patch you provide the link you told about using environment variables, so I guess if you provide this link it's because you prefer other way than structure parameters? Now you seem more agree to have this solution? After I describe the three possibility that we can use, params in structure, environment variable, key registers... Each solution is not perfect but I made a choice at this time using one. if you're ok now to add parameters in structure to pass pcsc context and handle like I've said at this time and now It's ok for me. The main goal is to have something working. > > Using registry to pass function parameters is weird to say the > least, maintaining copypaste code (like the cardmod driver) instead > of creating proper conditional behavior (in the PC/SC driver, which > it is by nature) is a bad luck wish for developers and maintainers. > > Yes, using context creation parameters is the solution that I had in > mind, which fits into OpenSC as needed. > > > If I introduce key register to limit witch programs can use cardmod is not > > > > a mistake but a functionnality, saying that it's not correct it's a > > nonsense > > > > after we can discuss about the utility of such functionnality... > > > > > > > > Concerning the patch, > > > > you provide adresses of pcsc context and handle in the structure > > VENDOR_SPECIFIC > > > > module opensc-cardmod32.dll to pcsc reader in module libopensc.dll, I'm > > not sure > > > > that such adresses can be provided betwen dll??? > > They are both LONG-s, why couldn't they be passed between DLL-s? Oh, sure adresses can be passed, but does addressed value can be correctly retreive? It's a question for my own curiosity about memory management under windows... > > -- > @MartinPaljak.net > +3725156495 > regards, François. _______________________________________________ opensc-devel mailing list opensc-devel@lists.opensc-project.org http://www.opensc-project.org/mailman/listinfo/opensc-devel