Re: [opensc-devel] win32: path to OpenSC windows registers

2010-12-10 Thread Viktor TARASOV
Nikolay Elenkov wrote:
 On 2010/12/09 20:22, Kalev Lember wrote:

   
 Victor, that's a very good idea to use standard MSI generated with WiX!

 Instead of adding 'Program Files\OpenSC' directory to PATH, it might be
 better to put all the deps (libopensc.dll, zlib.dll, iconv.dll, etc)
 into WinSxS [1] and only put the pkcs11 libraries in 'Program
 Files\OpenSC'.
 

 That would really be the best solution. It requires Windows XP and above 
 though,
 which is probably OK. BTW, in VS2010 MS has finally come to their senses and
 DLLs include a version number in the filename. ([1])
   

Thanks, I'll try.

My poor experience with SxS is not very encouraging --
on my development platform I do not managed to select the wanted version 
of CRT to link with.
It always takes the highest from the installed ones.
And so, on the target platform, that do not have this highest version, 
the libraries were not accepted.

 [1] http://msdn.microsoft.com/en-us/library/dd293574.aspx
   
Kind wishes,
Viktor.

 ___
 opensc-devel mailing list
 opensc-devel@lists.opensc-project.org
 http://www.opensc-project.org/mailman/listinfo/opensc-devel

   


-- 
Viktor Tarasov  viktor.tara...@opentrust.com

___
opensc-devel mailing list
opensc-devel@lists.opensc-project.org
http://www.opensc-project.org/mailman/listinfo/opensc-devel


Re: [opensc-devel] win32: path to OpenSC windows registers

2010-12-09 Thread Viktor TARASOV
Viktor TARASOV wrote:
 Nikolay Elenkov wrote:
   
 On 2010/12/07 16:03, Martin Paljak wrote:
   
 
 On Dec 7, 2010, at 4:41 AM, Nikolay Elenkov wrote:

 
   
 On 2010/12/07 2:36, Viktor TARASOV wrote:

   
 
 [1] 
 http://www.opensc-project.org/opensc/wiki/WindowsInstaller#PossibleinstallerstepsWindowsenvironmentdescription

   
 
 Here the OpenSC dlls are installed into 'system32'.
 Can an alternative method, like changing of the 'PATH' variable, be also 
 acceptable (for MSI)?

 
   
 This is bad, bad, bad. Especially since it also copies the OpenSSL dll in
 system32, and that breaks a lot of things. It should install in the main
 directory under c:\Program Files/ and add the bin directory to the PATH.
   
 
 Some software is very picky about the location from where it wants to load 
 certain modules, cryptographic modules being one of those things.

 
   
 Any specific examples? Both Firefox and Thunderbird work just fine with 
 PKCS#11
 on the PATH, and not in System32. Copying stuff in system32 was deprecated 
 ages
 ago. There is nothing special about a PKCS#11 DLL: unlike a Windows CSP, it 
 is
 not signed, there aren't any special check AFAIK (at least in Mozilla 
 software).
   
 

 The Gemalto and Oberthur (in the recent versions) middlewares install
 their DLLs into the 'Program Files'.
 My hidden motivation to do the same for the OpenSC MSI is that I do not
 managed to build the MSI
 that un-installs the DLLs installed in system32. The update and
 un-update of the PATH variable works remarkably good
Hello Martin,

can you validate r4936, please?

I propose to install OpenSC stuff into the the '\Program Files\OpenSC 
Project\OpenSC'
and install pkcs11-spy into the '\Program Files\OpenSC Project\PKCS11-Spy'

Kind wishes,
Viktor.



-- 
Viktor Tarasov  viktor.tara...@opentrust.com

___
opensc-devel mailing list
opensc-devel@lists.opensc-project.org
http://www.opensc-project.org/mailman/listinfo/opensc-devel


Re: [opensc-devel] win32: path to OpenSC windows registers

2010-12-09 Thread Kalev Lember
On 12/07/2010 10:43 AM, Viktor TARASOV wrote:
 The Gemalto and Oberthur (in the recent versions) middlewares install
 their DLLs into the 'Program Files'.
 My hidden motivation to do the same for the OpenSC MSI is that I do not
 managed to build the MSI
 that un-installs the DLLs installed in system32. The update and
 un-update of the PATH variable works remarkably good.


Victor, that's a very good idea to use standard MSI generated with WiX!

Instead of adding 'Program Files\OpenSC' directory to PATH, it might be
better to put all the deps (libopensc.dll, zlib.dll, iconv.dll, etc)
into WinSxS [1] and only put the pkcs11 libraries in 'Program
Files\OpenSC'. Polluting global DLL namespace (either by putting DLLs in
Windows\System32 or adding DLL files to PATH) makes it very hard for
other packages to ship DLL files with the same names.

[1] http://en.wikipedia.org/wiki/Side-by-side_assembly

Hope this helps,
Kalev
___
opensc-devel mailing list
opensc-devel@lists.opensc-project.org
http://www.opensc-project.org/mailman/listinfo/opensc-devel


Re: [opensc-devel] win32: path to OpenSC windows registers

2010-12-09 Thread Nikolay Elenkov
On 2010/12/09 20:22, Kalev Lember wrote:

 Victor, that's a very good idea to use standard MSI generated with WiX!
 
 Instead of adding 'Program Files\OpenSC' directory to PATH, it might be
 better to put all the deps (libopensc.dll, zlib.dll, iconv.dll, etc)
 into WinSxS [1] and only put the pkcs11 libraries in 'Program
 Files\OpenSC'.

That would really be the best solution. It requires Windows XP and above though,
which is probably OK. BTW, in VS2010 MS has finally come to their senses and
DLLs include a version number in the filename. ([1])

[1] http://msdn.microsoft.com/en-us/library/dd293574.aspx

___
opensc-devel mailing list
opensc-devel@lists.opensc-project.org
http://www.opensc-project.org/mailman/listinfo/opensc-devel


[opensc-devel] win32: path to OpenSC windows registers

2010-12-06 Thread Viktor TARASOV
Hi,

to reflect the commonly used template for the path to the windows registers
that the smart card producers are using 
([HKEY_...]Software\[Manufacturer]\[ProductName]),
I would like to add one more level to the OpenSC windows registers path.

To finally have:
RegOpenKeyEx(HKEY_CURRENT_USER, Software\\OpenSC Project\\OpenSC, ...
instead of actual
RegOpenKeyEx(HKEY_CURRENT_USER, Software\\OpenSC, ...


What do you think?

Kind wishes,
Viktor.

-- 
Viktor Tarasov  viktor.tara...@opentrust.com

___
opensc-devel mailing list
opensc-devel@lists.opensc-project.org
http://www.opensc-project.org/mailman/listinfo/opensc-devel


Re: [opensc-devel] win32: path to OpenSC windows registers

2010-12-06 Thread Martin Paljak
Hello,

On Dec 6, 2010, at 6:32 PM, Viktor TARASOV wrote:
 to reflect the commonly used template for the path to the windows registers
 that the smart card producers are using 
Following the common practices of a platform is a good idea. Yet it sometimes 
feel there is too much unnecessary bloat in Windows :)


 ([HKEY_...]Software\[Manufacturer]\[ProductName]),
 I would like to add one more level to the OpenSC windows registers path.
 
 To finally have:
 RegOpenKeyEx(HKEY_CURRENT_USER, Software\\OpenSC Project\\OpenSC, ...
 instead of actual
 RegOpenKeyEx(HKEY_CURRENT_USER, Software\\OpenSC, ...

HKLM vs HKCU is the only question for me. As on Unix OPENSC_CONFIG can be 
overridden from command line and so all tunables are user-modifiable, the 
default could be HKCU, then HKLM if HKCU key is not found.
Certain options would be nice to make unmodifiable to the normal in the future 
(set by administrator, only from opensc.conf/HKLM or similar) but that's 

Does it actually change anything? The only *smart card* related entries under 
...\Calais  (or CSP descriptors, which don't matter for OpenSC) don't depend on 
the other parts of the registry.

 What do you think?
Fine, as long as it is documented and universally followed [1]

As I'm (again) testing to see if the current codebase can be released as 
0.12.0, so the change should be done ASAP so that the Windows environment 
description would be fixed before the non-conforming setups spread.

[1] 
http://www.opensc-project.org/opensc/wiki/WindowsInstaller#PossibleinstallerstepsWindowsenvironmentdescription
-- 
@MartinPaljak.net
+3725156495

___
opensc-devel mailing list
opensc-devel@lists.opensc-project.org
http://www.opensc-project.org/mailman/listinfo/opensc-devel


Re: [opensc-devel] win32: path to OpenSC windows registers

2010-12-06 Thread Viktor TARASOV

Martin Paljak wrote:
 On Dec 6, 2010, at 6:32 PM, Viktor TARASOV wrote:
   
 to reflect the commonly used template for the path to the windows registers
 that the smart card producers are using 
 
 Following the common practices of a platform is a good idea. Yet it sometimes 
 feel there is too much unnecessary bloat in Windows :)

   
 ([HKEY_...]Software\[Manufacturer]\[ProductName]),
 I would like to add one more level to the OpenSC windows registers path.

 To finally have:
 RegOpenKeyEx(HKEY_CURRENT_USER, Software\\OpenSC Project\\OpenSC, ...
 instead of actual
 RegOpenKeyEx(HKEY_CURRENT_USER, Software\\OpenSC, ...
 

 HKLM vs HKCU is the only question for me. As on Unix OPENSC_CONFIG can be 
 overridden from command line and so all tunables are user-modifiable, the 
 default could be HKCU, then HKLM if HKCU key is not found.
 Certain options would be nice to make unmodifiable to the normal in the 
 future (set by administrator, only from opensc.conf/HKLM or similar) but 
 that's 

 Does it actually change anything? The only *smart card* related entries under 
 ...\Calais  (or CSP descriptors, which don't matter for OpenSC) don't depend 
 on the other parts of the registry.

   
 What do you think?
 
 Fine, as long as it is documented and universally followed [1]

 As I'm (again) testing to see if the current codebase can be released as 
 0.12.0, so the change should be done ASAP so that the Windows environment 
 description would be fixed before the non-conforming setups spread.
   
Ok, thanks.
In fact I would like to commit the build of MSI with WIX, that's why 
this question.



 [1] 
 http://www.opensc-project.org/opensc/wiki/WindowsInstaller#PossibleinstallerstepsWindowsenvironmentdescription
   
Here the OpenSC dlls are installed into 'system32'.
Can an alternative method, like changing of the 'PATH' variable, be also 
acceptable (for MSI)?



-- 
Viktor Tarasov  viktor.tara...@opentrust.com

___
opensc-devel mailing list
opensc-devel@lists.opensc-project.org
http://www.opensc-project.org/mailman/listinfo/opensc-devel