473,785 Members | 2,167 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

ASN.1 encoder & decoder

Can anyone provide guidance on building an ASN.1 decoder and encoder
in Python? This does not have to be a general purpose implementation,
drivenf from an ASN.1 template. It can be dedicated hard coded to a
particular template.

Doug Stell, ce*******@mchsi .com
Aug 25 '06 #1
6 7148
Doug Stell <ce*******@mchs i.comwrites:
Can anyone provide guidance on building an ASN.1 decoder and encoder
in Python?
<http://sourceforge.net/projects/pyasn1/>?
Aug 25 '06 #2
I looked at pyasn1. Unfortunately, it is not useful and provides a C
interface. Thanks, anyhow.

I figure that I will have to write my own, but am unsure of the best
approach. Nested lists and distionaries might be useful and I am
looking to the feasibility of those mechanisms.

On Fri, 25 Aug 2006 23:20:41 +0100, Bruce Stephens
<br**********@c enderis.demon.c o.ukwrote:
>Doug Stell <ce*******@mchs i.comwrites:
>Can anyone provide guidance on building an ASN.1 decoder and encoder
in Python?

<http://sourceforge.net/projects/pyasn1/>?
Aug 25 '06 #3
Doug Stell <ce*******@mchs i.comwrites:
Can anyone provide guidance on building an ASN.1 decoder and encoder
in Python? This does not have to be a general purpose implementation,
drivenf from an ASN.1 template. It can be dedicated hard coded to a
particular template.
There might be some useful code in www.trevp.com/tlslite .
Aug 25 '06 #4
Doug Stell <ce*******@mchs i.comwrites:
I looked at pyasn1. Unfortunately, it is not useful and provides a C
interface. Thanks, anyhow.
What makes you say that? It appears to me (looking at the code in
CVS) to be written entirely in Python, and the home page,
<http://pyasn1.sourcefo rge.net/shows examples clearly with a Python
interface.

I've no idea whether or not it's useful in any other sense.

[...]

Aug 26 '06 #5
I looked at pyasn1. Unfortunately, it is not useful and provides a C
interface. Thanks, anyhow.
pyasn1 is a pure-python implementation. C interface is not supported.
I figure that I will have to write my own, but am unsure of the best
approach. Nested lists and distionaries might be useful and I am
looking to the feasibility of those mechanisms.
Try looking at the pyasn1 homepage http://pyasn1.sf.net where some
design ideas were discussed.

-ilya

Aug 27 '06 #6
Thanks Paul. This is exactly the type andlevel of implementation that
I was looking for.

I will look at the other implementation again.

On 25 Aug 2006 16:32:46 -0700, Paul Rubin
<http://ph****@NOSPAM.i nvalidwrote:
>Doug Stell <ce*******@mchs i.comwrites:
>Can anyone provide guidance on building an ASN.1 decoder and encoder
in Python? This does not have to be a general purpose implementation,
drivenf from an ASN.1 template. It can be dedicated hard coded to a
particular template.

There might be some useful code in www.trevp.com/tlslite .
Aug 28 '06 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
3345
by: S Etchelecu | last post by:
I'm having trouble understanding the MIME::Decoder usage. Within the context of a MIME email handling program I have an array, @data, and I want to uuencode it. I thought I could instantiate a MIME::Decoder with an encoding of 'x-uuencode' and then call the encode method as, my $decoder = new MIME::Decoder('x-uuencode'); $decoder->encode(@data, @uudata); However, the encode method only accepts STREAMs as arguments. Obviously I
0
501
by: rockstar1971 | last post by:
Hello. I’m working with the Windows Media Encoder SDK to create an online jukebox for myself, but I’m having problems getting it to work. Here’s what I want to do: I’ve got a large collection of mp3 files that I listen to at work from my home server. I simply share them out from IIS and then open playlist files in WMP to play lists of songs. This works well fairly well. However, most of my mp3s are encoded at 192kbps or higher,...
3
11584
by: Matt | last post by:
I'm trying to simply convert a .avi file recorded by our program to a wmv file, of course compressed as possible. I've looked at the examples provided by microsoft @ http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wmencode/htm/completecodeexamples.asp in both CSharp and VB6. I can't get them to compile. Some of the objects listed (namely the IWMEncVideoSource2 object in CSharp and IWMEncAudioSource and...
2
3302
by: anirudhvr | last post by:
Hi, I needed a basic binary to ascii encoder, so I wrote this piece of code: /* Encoding algo: suppose 11111010 is the byte to be encoded. It is first broken up into two 4-bit parts (1111 and 1010) This 4-bit quantity is then padded between a 01 and a 10, ie, 01xxxx10 will be written out to the output file.
15
3694
by: aarklon | last post by:
Hi all, this is the program which I saw in my colleagues book. the program was run on turbo C++ 3.0 compiler /*beginning of header file huff.h*/ #ifndef _HUFF_H_ #define _HUFF_H_
1
2554
by: metaosp | last post by:
Hi, Could anyone suggest a nice, small url encoder/decoder class (or function) with source code? Thanks, Metaosp
0
3803
by: Crisco www.misericordia.com.br | last post by:
Hi, friends! I am develop a simple encoder app, one form with one button that start the encoder. This is my code: ============================================================= Option Explicit On
2
3481
by: ldpfrog | last post by:
Basically my friend's parents used to log his AIM and email so we made a barbaric version of an encoder that we could type in what we wanted and get random letters out. The only problem is that I did it in Truebasic, and I am new to VB. I have the interface layed out with an Encode button and a Decode button with an Input and an output/log. Eventually I want to have it just with universal hotkeys to where you can highlight a text and it...
0
2088
by: jsnidely | last post by:
Hi, Does anyone have a BCH encoder/decoder written in either C or C++ (or C#)? I am looking for the CCSDS version of the algorithum using (63,56). If anyone has one or knows where the code for this might be posted please let me know. Thanks, Steve
0
9647
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9489
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
1
10100
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9959
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8988
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7509
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6744
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5528
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
2893
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.