Hi

What I would like to do is to extract the payload from the PER encoded
PDU then encrypt it and replace the payload in the PDU with the
encrypted "payload". This way of describing data with different views
requires something like a "C" UNION functionality. Is this available in
ASN.1?

How is this normally treated in a ASN1 specification? 

The padding is needed since I currently operate on the PER encoded data
when I replace the payload the size of it must fit with the block size
of encryption algorithm. 

/Henrik Andersson


-----Original Message-----
From: Conrad Sigona [mailto:[EMAIL PROTECTED] 
Sent: den 2 december 2006 12:22
To: Andersson Henrik
Cc: [email protected]
Subject: Re: [Asn1] Temporarily encrypt part of a ASN.1 module

> I have designed an ASN.1 module. When this module is transmitted a
part
> of it shall be encrypted. I wonder if there is a nice way to handle
this
> in ASN.1. I have included a simplified module below to describe the
> problem.
>
> PDU::= SEQUENCE {
> header        Header,
> payload       Payload - -this part shall be encrypted during transfer
> }
>
> Payload SEQUENCE {
> dataA INTEGER,
> dataB INTEGER,
> padding       OCTETSTRING
> }
>
> During transfer the Payload shall be encrypted. In my current solution
I
> have been forced to add a padding field to make sure that the data
size
> fits with the encryption algorithm. I presume that there is a better
way
> to describe this with ASN.1.

Please be a little more precise. Is it that Payload, as a SEQUENCE,
would 
be encrypted and inserted into PDU as something else (not a SEQUENCE),
or 
rather that dataA and dataB are each encrypted and inserted into
Payload.

Please also explain the point of padding. Is it that the encryption 
algorithm only accepts fixed size blocks?

=====================================================================
Conrad Sigona                    Voice Mail     : 1-732-302-9669 x400
OSS Nokalva                      Fax            : 1-614-388-4156
[EMAIL PROTECTED]                   My direct line : 1-315-845-1773
_______________________________________________
Asn1 mailing list
[email protected]
http://lists.asn1.org/mailman/listinfo/asn1

Reply via email to