How to import SNMP walks into mimicview gambit as agents? - snmp

I am fairly new to the program being used which is MimicView Gambit. From what I know it mimics a node/switch/router to simulate real time activity.
What I need to do is using a SNMP walk results to somehow import the .wlk file into mimicview as an agent. An agent is referred to as the node/switch/router.
Does anyone have any information on how to approach this or some leads/documentation?

Thanks for the question. The quickest answer will come from support#gambitcomm.com.
The simplest way to create a simulation is to record the device directly,
for example, see this Youtube video.
If you have a walkfile, you can use Simulation->Record File in MIMICView.
There are many more ways to import devices into the SNMP Simulator
as documented in the online documentation.

I had never heard before about MimicView, but I'm working on similar project. So fast view via Mimic's FAQ seems to give the answer. In short, as far as I understand you have to write file using net-snmp snmpwalk command with option -One, like
snmpwalk -One -v2c -cpublic ip.of.your.device > result.wlk
and then fed result to MimicRecorder, eg. in MIMICView use Simulation->Record File. In any case you should read that link and the walkfile converters section in the Utilities Guide for more details.

Related

URL filtering using driver for OS X

I have an requirement for my client, where in i need to block particular URL based on the user input.
I was thinking to implement this by building a driver, From which i can get the packet response with all the details through this I can block/allow by building an application.(THIS is similar to what "netfilter" driver does in windows)
But as i read through the docs and websites i did not get enough information to proceed with for this particular requirement.(I found about bpf but there was not enough details to proceed with)
As I am very much NEW to the driver field,Can someone suggest me how to proceed in this case.(Steps how to proceed)
Note:I found lot of projects/docs related to USB drivers and all but they were not giving enough idea to proceed for further.
"URL" is very broad, and depending on the kinds of URL (what protocols? What about encryption?) and required granularity, some other solution than a custom kext might be a better approach. Not knowing your requirements, I can't say whether that's the case.
What I can answer, however, is that if you do decide to do this from a kext, Network Kernel Extensions are what you need to look into.
Apple also provides the enetlognke example code to illustrate how to use the NKE APIs.

How to implement frames and commands on omnet++?

I'm working on a project evaluation of TSCH feature in 802.15.4. I don't know how to implement the Enhanced beacon and the request and confirm messages between nodes on omnet++.
This is quite a generic question. Generally I would look into the current codebase of INET (2.99 and later recommended) and would try to find similar features as a starting point.

Where to begin with SNMP agent implementation?

before I start I realise there are a few SNMP related questions here already but not many seem to have been answered - that could mean I'm asking in the wrong place but I don't know where else to go at the moment.
I've been reading up as best I can on SNMP for a couple of days but am finding it difficult to get my head around what is meant to be happening. The idea is eventually we will integrate SNMP into our Java application server which will allow the end users to incorporate it into their pre-existing Network Management Systems(NMS).
Unfortunately I'm feeling entirely confused by what is meant to be going on. From what I understood from talking to the end users (which was unfortunately before any research) was that the monitoring allows their existing NMS to give their admin guys a view of the vital statistics in a tree type display, giving them feedback regarding different parts of the system at a high level and allowing them to dig down into specific subsystems.
From reading around we would implement an 'Agent' which has several defined interfaces allowing for GET requests etc to be processed and responded to. That makes sense but I am at a loss to work out what the format of the communication is - there don't seem to be any specific examples of what any of the messages look like, how the information is encoded.
More of my confusion though is regarding Management Information Base(MIB). I had, wrongly, assumed that the interface of the agent would allow for the monitored attributes to be requested and then in turn the values for those attributes requested. Allowing any new Agent to be started and detected without any configuration on the NMS end (with the exception of authentication in v3). This, if I understand correctly, is not the case and the Agent must instead define MIBs which can be used by the NMS to determine those attributes. My confusion is increased when people start referring to thousands of existing MIBs and that they can be reused which I don't understand. Is the intention that a single MIB definition can be used to say describe how a particular attribute of a network device (something simple like internet connected on a router:yes/no) for many different devices? If so I don't believe that our software would allow the monitoring of anything common to any other device/system but should we be looking for already exising MIBs? At the moment I don't really see any good rational for such a system, surely it would be easier for the Agent to export that information - so I'd appreciate it if someone could enlighten me!
I think it would help if I was able to setup a simple SNMP agent and some sort of client, I could begin to see the process and eventually inspect the communication between the two but am finding it difficult to find anywhere that provides any information on doing such a thing. Nagios has been recommended to us as a test 'client'/NMS but their 'get started quick' section recommends downloading a 600Mb virtual machine - surely there is a quicker way to get started?
Any help or suggestions will be appreciated, I have been through the Wiki page but it doesn't seem to go into much detail about the MIBs and the having not had to deal with anything like the referenced RFCs before, while they may contain all of the information they seem completely impenetrable to me at the moment. Or if there are any books that can be recommended for an overview and implementation of v3?
Thanks for reading and even more thanks if you think you can help!
It seems to me that you read all SNMP information piece by piece in an disorganized way. This is highly not recommended and of course lead you to confusion.
What about forgetting what you have learnt so far and dive into a good book such as Essential SNMP?
http://shop.oreilly.com/product/9780596008406.do
Click the Google Preview icon to preview it please.
You could not depend on a network forum to tell you the ABCs, as that's impractical I find out.
The communications interface is SNMP. That's the protocol used for transmission (usually on top of UDP). The thing that services information requests is an SNMP Agent. The thing that sends information requests is an SNMP Manager.
The definition of what information should be made available by the Agent, and requested by the Manager, goes in a MIB. A MIB is the "glue", a directory of what sort of things any particular system can/should offer. It maps numeric codes to names and types that allow us to make sense of the data, much like how a phone directory maps phone numbers to people's names and addresses.
Generally you would create and ship and use your own MIBs that can describe aspects specific to your own product, but you are supposed to service some standard information requests as well, which are defined in existing MIBs. Yes there are thousands of other pre-existing MIBs and the likelihood that you need more than one or two of these is remote. They are typically published versions of MIBs for existing products.
The conventional way to "toy around" is to install Net-SNMP (a software suite that includes an agent implementation and allows you to "bolt on" your own logic and your own MIBs fairly easily) then examine the results using a packet capturer like Wireshark.
For a fuller implementation in production you may stick with Net-SNMP, or write your own Agent software, or do what I did and create a hybrid of the two that's a little more flexible and performant but uses Net-SNMP's backend for handling all the low-level SNMP stuff.
Your first step, though, is to read a book or some other teaching material that can clear all your misconceptions, because guesswork won't cut it.
I had success using the samples from this page. Both the shell and Perl NetSNMP code was very straightforward to implement and query.

net-snmp: how should I approach the project of making a bilingual snmpd?

I apologize that this question comes from the uninformed, huddled masses: I've been away from net-snmp for three years and I've missed all of the developments.
I have to deliver a bilingual v2c/v3 snmpd for use in an embedded Linux system.
I expect to use the superb net-snmp sources. What is the right approach to marshalling these sources, where "right" == straightforward, uncomplicated, vanilla, and "it just works"?
Thanks so much, everybody. And I apologize again for my out-of-dateness.
Edit: Why do I need this input? I have a lot of experience with snmp v2c in general; some experience with net-snmp; and little experience with snmp v3. Because I'm new to v3, I'm looking for a cookbook approach from someone who's done it so I can avoid the many undocumented pitfalls and hurdles that my experience tells me lie in the path of anyone building an agent from net-snmp sources.
First, Net-SNMP is already tri-lingual under the hood. If you configure it to accept v1, v2c and v3 it'll happily accept and respond to all 3 protocol versions without changing a thing.
Second, to get snmpv1/2c working, all you need in your snmpd.conf file is:
rocommunity COMMUNITYNAME
Where, COMMUNITYNAME is the super-secret insecure community/password you want to use.
For SNMPv3, I'm assuming you want to use SNMPv3 with USM. I suggest you start by reading the Net-SNMP tutorial on Securing SNMP traffic and go from there.
Note also, you can run snmpconf -g basic_setup to get more help with the above as well as with other options.

Telnet lib and language choice for cross OS telnet client?

I'm looking to start a MUD client application, which connects to a MUD hosted on a telnet server. The only thing important to me is that it runs painlessly and efficiently across any OS. Aside from that requirement, I'm not really sold on any language.
So I'm looking for a freely available telnet client library on which I can base my application, so I don't have to deal with the details of the protocol too much.
I would always consider Twisted for this kind of thing (Python).
The beauty is that if you later decide to swap it out to SSH or anything more secure than telnet, you can with little pain.
Twisted, twisted, twisted!
To use telnet, see package twisted.conch.telnet. It's got some spartan API docs, but the real information on using it comes from searching on Google Code Search, such as this nugget from grailmud - a MUD server.
For all of my MUD programming, I just created my own routines from the ground up using the RFCs.
In case you'd like to avoid some of my pain, I wrapped it up into a fairly simple C# class that handles Telnet properly. In case you'd like to peruse it, you can view it here.
This code has been copy/pasted and run on Windows and on Linux (through Mono) on a handful of separate projects and works pretty good.
There is a telnet interface in CPAN if you like Perl. It's pretty minimal, but it should get the job done.
[edit]
libcurl is also supposed to be able to do telnet, although I couldn't find any examples of it.
pmc ( http://sourceforge.net/projects/perlmudclient/ ) was an attempt to do exactly this. I've spent some of the last week going through it; it uses an older modified version of Net::Telnet to do its connectivity work.
My problem is that Net::Telnet seems to have a blocking interface when a partial line is sent by the server, i.e. a line not terminated by a newline. It has two features that support this (waitfor and its prompt mechanism), because almost all telnet servers have prompts that are not newline-terminated.
MUDs often have "prompts" that are non-standard and vary through the course of the game; the MUD I admin on has a "Your choice: " prompt as its login [it's not just for usernames], and many game features present alternative prompts. So I suspect you'll need to bear this in mind when you go looking for a cross-platform Telnet library!
If you like C, I heartily recommend libtelnet. It will maintain an internal state that does all the IAC sequence parsing for you, and handles option negotiation using the Q method.

Resources