Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

encoding OIDs using BER

Posted on 2000-02-14
6
Medium Priority
?
230 Views
Last Modified: 2010-03-18
Can anybody give me an explanation on how to encode OID components using BER. I know the first two use the scheme 40x+y, but my problem is with components 3 onwards larger than 127. For example, how does 134 become 81 02 (hex).

Thanx
0
Comment
Question by:nitelord
  • 5
6 Comments
 
LVL 3

Expert Comment

by:RobWMartin
ID: 2520449
You sure the BER for 134 is not 81 06?

0
 
LVL 3

Expert Comment

by:RobWMartin
ID: 2520467
Using 134;  binary is 10000110.  You start with the least sig bit of the least sig byte and grab the last 7 bits, 0000110.  Then look at the 8 th bit; if it was zero we would stop, but since it is 1, we need another octet, 10000001.  The most sig bit says there are more octets to follow; i.e. it is the continuation bit.  When it is 0 the decoder knows it has the complete component, when 1 it knows to grab the next octet.  Thus, if the 8th bit is significant, i.e. 1, for our data then it must be moved left into another octet to make room for the continuation bit.  Final encoding:

10000001 0000110
    81      06

Hope this helps
Rob
0
 
LVL 3

Expert Comment

by:RobWMartin
ID: 2520478
There are probably links out there that explain it better; I'll look.
0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 
LVL 3

Accepted Solution

by:
RobWMartin earned 900 total points
ID: 2520496
Well, that was easy.  Here is a good explanation link:

http://developer.novell.com/research/devnotes/1999/november/02/05.htm

I should've done this first.  Would have saved some calculator work:)

Rob
0
 

Author Comment

by:nitelord
ID: 2520701
when I calculated it I got 81 06 but the book I'm using (pg 589, Feit, Sidnie, SNMP a guide to network management) gave that value. I'll try a few more, thanx

0
 
LVL 3

Expert Comment

by:RobWMartin
ID: 2528989
So how's it going?

0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I have seen several blogs and forum entries elsewhere state that because NTFS volumes do not support linux ownership or permissions, they cannot be used for anonymous ftp upload through the vsftpd program.   IT can be done and here's how to get i…
Note: for this to work properly you need to use a Cross-Over network cable. 1. Connect both servers S1 and S2 on the second network slots respectively. Note that you can use the 1st slots but usually these would be occupied by the Service Provide…
If you're a developer or IT admin, you’re probably tasked with managing multiple websites, servers, applications, and levels of security on a daily basis. While this can be extremely time consuming, it can also be frustrating when systems aren't wor…
Please read the paragraph below before following the instructions in the video — there are important caveats in the paragraph that I did not mention in the video. If your PaperPort 12 or PaperPort 14 is failing to start, or crashing, or hanging, …

782 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question