<?xml version="1.0" ?>
<rss version="2.0">
<channel>
	<title>Lev Walkin → ASN.1 Exposed: extensibility</title>
	<link>http://lionet.info/asn1c/blog/tag/extensibility</link>
	<description>Entries of Lev Walkin → ASN.1 Exposed tagged with 'extensibility'</description>


	<item>
		<title>Question: Extensibility and dropping fields</title>
		<description><![CDATA[
<p>
Today's email was asking me about an interesting case of ASN.1 extensibility.
Usually, extensibility means adding new members to existing structures. In this case, the user was asking whether ASN.1 supports removing structure members.

<p>
<blockquote>
Hello, Mr. Walkin.
 
<p>
I am using the ASN.1 compiler and for an application I am developing. I am using this to store the datastructure in a file, for persistence. I am trying to find out whether forward compatibility is support. By this I mean the following.
 
<p>
In the version 1 I have the following structure:
<div><pre style="float: left; padding-right: 50px; min-width: 200px;">Struct a {
	Int x;
	Int y;
	Int z;
}</pre><div style="clear: left;"></div></div>
 
I store the data x = 111; y = 222 and z = 333;
 
<p>
Now I upgrade the software to the version 2 where in the new struct is:
 
<div><pre style="float: left; padding-right: 50px; min-width: 200px;">Struct a {
	Int x;
	<code class="comment">// int y is removed</code>
	Int z;
}</pre><div style="clear: left;"></div></div>
 
<p>
Now when I read the existing file (generated with the older version of ASN.1 specification) with the newer version of the software, I get the following data back: x = 111, and z = 222.

<p>
Can you please tell me whether it is possible to get x = 111 and z = 333. If yes, then what ASN syntax should I follow?
 
I am using der_encode and ber_decode.
</blockquote>
]]></description>
		<link>http://lionet.info/asn1c/blog/2010/09/21/question-extensibility-removing-fields</link>
		<guid>http://lionet.info/asn1c/blog/2010/09/21/question-extensibility-removing-fields</guid>
	</item>


</channel></rss>
