Switch branches/tags
Nothing to show
Find file History
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
..
Failed to load latest commit information.
gth
Makefile
README
aal5.py
gth.py
play.py
record.py
sniff_isup.py

README

Author: matthias@corelatus.se
----------------------------------------------------------------------

Introduction

  This is example code in Python for a Corelatus GTH. It depends on the
  'pyparsing' package.

  The examples were tested on python 2.6.6 and 2.5.4 on linux.

  Each example is built on top of a little library, gth/apilib.py, which
  lets you hack up python code to do pretty much anything supported by
  the GTH, i.e. you don't have to write your own parser.

  Disclaimer: I'm a python beginner, i.e. if it looks weird, then that's
              most likely because I didn't know better. Suggestions for
              improvement are welcome to matthias@corelatus.se


Command line for exploring GTH configuration
--------------------------------------------

  'gth.py' does (almost) all the things which the GTH's built-in SSH
  CLI can do:

    - enable and disable E1/T1 and SDH/SONET interfaces

    - query attributes on all resources, e.g. read out the counters
      for E1/T1, SDH/SONET and Ethernet interfaces.

    - set attributes on resources, e.g. configure the IP address and
      NTP server

    - zero (reset) counters on resources, e.g. clear the error counters
      on E1/T1 or SDH/SONET interfaces

    - reboot

  Run 'gth.py' without arguments to see some examples.


Recorded file playback
----------------------

  Plays back a previously recorded timeslot on an E1/T1. The GTH
  can record bit-exact copies of timeslots and then play back
  such files at a later time. Typical use:

    >./play.py 172.16.2.7 1A 16 signalling.raw
    All done, sent 2276 octets

  The file could contain audio (8kHz Alaw, without a header) or
  it could contain signalling. The GTH treats both the same. Most
  likely it's a dump of an E1/T1 you recorded earlier using the next
  example.


E1/T1 timeslot dump to a file
-----------------------------

  This is the opposite of 'recorded file playback'. It copies the
  data on the given E1 to a file on your PC. Typical use:

    >./record.py 172.16.2.7 1A 16 4000 signalling.raw
    All done, wrote 4000 octets

Sniff ISUP
----------

  Print out when calls start and stop on an SS7 link.

  Uses the GTH to decode MTP-1 and MTP-2. MTP-3 and ISUP decoding
  is done in python. Typical use:

     >./sniff_isup.py gth21 1A 16
     IAM called party: 21255512 calling party: 11313555 CIC=0
     ignoring ISUP address complete
     ignoring ISUP answer
     ignoring ISUP release
     RLC on CIC=0

# eof