yzt | 2 Nov 01:01 2008
Picon

Need For Specific Cryptographic Primitive


Hi,

In my work, I need a cryptographic primitive (a cipher, to be more
specific) with the following attribute:
If we define the the encryption function as "E(k,p)" where "k" is the
key and "p" is the plain text, I need the cipher to have the property
that "E(k2, E(k1, p)) = E(k3, p)". In other words, I need the result
of the double encryption of any given plaintext with two different
keys, be equal to a single encryption with another key.
Obviously, I also need the "k3" above to be computable given "k1" and
"k2", but (ideally) neither "k1" nor "k2" should be retrievable given
the other two keys.

Now, I don't have a strong theoretical background in cryptography, so
I don't even know what this property is called, or even whether it has
a specific name (that's why I had to choose such a non-descriptive
subject,) but as I understand it, this is generally an undesirable
property in a cipher.
Can such a property be implemented using conventional cryptographic
primitives? I would prefer the use of a block cipher, but public key-
based solutions wouldn't be too problematic either. Does anyone have
any advice as how should I go about implementing this? Does Crypto++
have any features to help me here?

I'm not even sure whether this mailing list is the proper place to ask
such questions. If so, I'd appreciate to be directed to the proper
place to ask this. I apologize if I'm violating any rules or
conventions.

(Continue reading)

dreijer | 2 Nov 02:01 2008
Picon

Missing quotation marks in 64-bit custom build rule


Hi,

The 64-bit compilation of Crypto++ 5.5.2 fails when trying to compile
the assembly file if the path to the library includes spaces. For
instance, for the Release configuration, the custom build rule looks
as follows:

<FileConfiguration
	Name="Release|x64"
	>
	<Tool
		Name="VCCustomBuildTool"
		CommandLine="ml64.exe /c /nologo /Fo&quot;$(IntDir)
\x64masm.obj&quot; /Zi $(InputPath)&#x0D;&#x0A;"
		Outputs="$(IntDir)\x64masm.obj"
	/>
</FileConfiguration>

I fixed the problem by adding quotation marks around $(InputPath),
like so:

<FileConfiguration
	Name="Release|x64"
	>
	<Tool
		Name="VCCustomBuildTool"
		CommandLine="ml64.exe /c /nologo /Fo&quot;$(IntDir)
\x64masm.obj&quot; /Zi &quot;$(InputPath)&quot;&#x0D;&#x0A;"
		Outputs="$(IntDir)\x64masm.obj"
(Continue reading)

dreijer | 2 Nov 04:54 2008
Picon

Missing quotation marks in 64-bit custom build rule


Hi,

The 64-bit compilation of Crypto++ 5.5.2 fails when trying to compile
the assembly file if the path to the library includes spaces. For
instance, for the Release configuration, the custom build rule looks
as follows:

<FileConfiguration
        Name="Release|x64"
        >
        <Tool
                Name="VCCustomBuildTool"
                CommandLine="ml64.exe /c /nologo /Fo&quot;$(IntDir)
\x64masm.obj&quot; /Zi $(InputPath)&#x0D;&#x0A;"
                Outputs="$(IntDir)\x64masm.obj"
        />
</FileConfiguration>

I fixed the problem by adding quotation marks around $(InputPath),
like so:

<FileConfiguration
        Name="Release|x64"
        >
        <Tool
                Name="VCCustomBuildTool"
                CommandLine="ml64.exe /c /nologo /Fo&quot;$(IntDir)
\x64masm.obj&quot; /Zi &quot;$(InputPath)&quot;&#x0D;&#x0A;"
                Outputs="$(IntDir)\x64masm.obj"
(Continue reading)

Wei Dai | 2 Nov 21:31 2008

Re: Need For Specific Cryptographic Primitive


Take a look at these two papers:

"An Improved Construction for Universal Re-encryption", Peter Fairbrother
http://eprint.iacr.org/2003/255.pdf

"Conversion Functions for Symmetric Key Ciphers", Debra L. Cook and Angelos 
D. Keromytis
http://www1.cs.columbia.edu/~dcook/pubs/covfun-jias0606.pdf

These primitives are not directly implemented in Crypto++, but you can do it 
yourself easily with the components in Crypto++. If these two papers don't 
have what you are looking for, I suggest you post to the sci.crypt Usenet 
group(http://groups.google.com/group/sci.crypt) and explain what you are 
trying to do with this primitive (i.e. what is your application). If you do 
that, link to that post here, because I'm curious too.

--------------------------------------------------
From: "yzt" <yaserzt <at> gmail.com>
Sent: Saturday, November 01, 2008 4:01 PM
To: "Crypto++ Users" <cryptopp-users <at> googlegroups.com>
Subject: Need For Specific Cryptographic Primitive

>
> Hi,
>
> In my work, I need a cryptographic primitive (a cipher, to be more
> specific) with the following attribute:
> If we define the the encryption function as "E(k,p)" where "k" is the
> key and "p" is the plain text, I need the cipher to have the property
(Continue reading)

Chris Morgan | 3 Nov 00:30 2008
Picon

[PATCH] - gcc 4.3.2 compile fixes for memset used with zero length

gcc 4.3.2 detects the use of memset() with zero for the length
parameter. I'm not sure if this is a new thing for glibc that gcc is
finally checking but in any case it showed up in Ubuntu Intrepid.

There are some template classes whos methods are passed values that
result in memset being called with a zero length. Because the
definitions are in header files these calls are inlined, so even
though its a method call because it is inlined gcc can see that the
value results in the memset length always being zero.

In my case I'm seeing compile warnings and failure during linking to
find the __warn_memset_zero_len function.

The attached patch adds checking of the memset length parameter in the
few locations that gcc warned about, skipping the call to memset if
the length value is zero.

Chris

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the "Crypto++ Users" Google Group.
To unsubscribe, send an email to cryptopp-users-unsubscribe <at> googlegroups.com.
More information about Crypto++ and this group is available at http://www.cryptopp.com.
-~----------~----~----~----~------~----~------~--~---

Mouse | 3 Nov 01:25 2008
Picon

RE: Need For Specific Cryptographic Primitive


I want to add that from cryptographic point of view for a cipher to possess
the property requested by YZT would be a VERY bad sign.

-----Original Message-----
From: cryptopp-users <at> googlegroups.com
[mailto:cryptopp-users <at> googlegroups.com] On Behalf Of Wei Dai
Sent: Sunday, November 02, 2008 15:32
To: yzt; Crypto++ Users
Subject: Re: Need For Specific Cryptographic Primitive

Take a look at these two papers:

"An Improved Construction for Universal Re-encryption", Peter Fairbrother
http://eprint.iacr.org/2003/255.pdf

"Conversion Functions for Symmetric Key Ciphers", Debra L. Cook and Angelos
D. Keromytis http://www1.cs.columbia.edu/~dcook/pubs/covfun-jias0606.pdf

These primitives are not directly implemented in Crypto++, but you can do it
yourself easily with the components in Crypto++. If these two papers don't
have what you are looking for, I suggest you post to the sci.crypt Usenet
group(http://groups.google.com/group/sci.crypt) and explain what you are
trying to do with this primitive (i.e. what is your application). If you do
that, link to that post here, because I'm curious too.

--------------------------------------------------
From: "yzt" <yaserzt <at> gmail.com>
Sent: Saturday, November 01, 2008 4:01 PM
To: "Crypto++ Users" <cryptopp-users <at> googlegroups.com>
(Continue reading)

Vadym Fedyukovych | 3 Nov 15:41 2008
Picon

Re: Need For Specific Cryptographic Primitive


ElGamal scheme may have some (not all) properties described

On Sat, Nov 01, 2008 at 05:01:20PM -0700, yzt wrote:
> 
> Hi,
> 
> In my work, I need a cryptographic primitive (a cipher, to be more
> specific) with the following attribute:
> If we define the the encryption function as "E(k,p)" where "k" is the
> key and "p" is the plain text, I need the cipher to have the property
> that "E(k2, E(k1, p)) = E(k3, p)". In other words, I need the result
> of the double encryption of any given plaintext with two different
> keys, be equal to a single encryption with another key.
> Obviously, I also need the "k3" above to be computable given "k1" and
> "k2", but (ideally) neither "k1" nor "k2" should be retrievable given
> the other two keys.
> 
> Now, I don't have a strong theoretical background in cryptography, so
> I don't even know what this property is called, or even whether it has
> a specific name (that's why I had to choose such a non-descriptive
> subject,) but as I understand it, this is generally an undesirable
> property in a cipher.
> Can such a property be implemented using conventional cryptographic
> primitives? I would prefer the use of a block cipher, but public key-
> based solutions wouldn't be too problematic either. Does anyone have
> any advice as how should I go about implementing this? Does Crypto++
> have any features to help me here?
> 
> I'm not even sure whether this mailing list is the proper place to ask
(Continue reading)

tunga | 5 Nov 10:37 2008
Picon

Crypto++ and C#


Hi all,

I am a newbie and I wonder whether I can use this library within C#...
I mean is it possible to compile it with MS VC++ and then use it in
C#... (is there a way to produce wrapper classes?)

thanks in advance
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the "Crypto++ Users" Google Group.
To unsubscribe, send an email to cryptopp-users-unsubscribe <at> googlegroups.com.
More information about Crypto++ and this group is available at http://www.cryptopp.com.
-~----------~----~----~----~------~----~------~--~---

UnFleshed One | 7 Nov 05:01 2008
Picon

Re: Crypto++ and C#


tunga wrote:
> Hi all,
>
> I am a newbie and I wonder whether I can use this library within C#...
> I mean is it possible to compile it with MS VC++ and then use it in
> C#... (is there a way to produce wrapper classes?)
>
>   

Yes, the same way you use any unmanaged C++ in C# -- create managed 
wrapper assembly around unmanaged C++ code. Managed C++ can link to 
unmanaged C++ libraries, and C# can load managed C++ assemblies. There 
are few tricks you need to do make sure CRT is initialized and managed 
strings properly converted over to unmanaged memory (you don't want GC 
to yank your string underneath you).

Best way is to reduce visibility of cryptopp code to C# as much as 
possible, so it puts some data in and gets some data out. So no fancy 
filter chains :(

Let me know if you need more details.

(But anyway, don't use C# -- C++ is much better :)).

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the "Crypto++ Users" Google Group.
To unsubscribe, send an email to cryptopp-users-unsubscribe <at> googlegroups.com.
More information about Crypto++ and this group is available at http://www.cryptopp.com.
-~----------~----~----~----~------~----~------~--~---
(Continue reading)

tunga | 7 Nov 08:33 2008
Picon

Re: Crypto++ and C#


Hi UnFleshedOne,

thanks four your answer.

and Sorry for the coming silly question (I have never used C++ code
from C# before) but how to create managed
wrapper assembly around unmanaged C++ code???

thanks in advance,

On Nov 7, 6:01 am, UnFleshed One <zolen... <at> gmail.com> wrote:
> tunga wrote:
> > Hi all,
>
> > I am a newbie and I wonder whether I can use this library within C#...
> > I mean is it possible to compile it with MS VC++ and then use it in
> > C#... (is there a way to produce wrapper classes?)
>
> Yes, the same way you use any unmanaged C++ in C# -- create managed
> wrapper assembly around unmanaged C++ code. Managed C++ can link to
> unmanaged C++ libraries, and C# can load managed C++ assemblies. There
> are few tricks you need to do make sure CRT is initialized and managed
> strings properly converted over to unmanaged memory (you don't want GC
> to yank your string underneath you).
>
> Best way is to reduce visibility of cryptopp code to C# as much as
> possible, so it puts some data in and gets some data out. So no fancy
> filter chains :(
>
(Continue reading)


Gmane