Commit Graph

36 Commits

Author SHA1 Message Date
Cort Buffington
ad57ed0ebb Added Peer/Master Timeout and Removal 2013-08-01 15:09:20 -05:00
Cort Buffington
244f53778a Added "self" note for self peer in the print peer-list function 2013-07-31 20:56:49 -05:00
Cort Buffington
851b0e9c4d More work on validation 2013-07-31 20:46:03 -05:00
Cort Buffington
835011d1a8 Fixed formatting error in peer list 2013-07-31 13:58:53 -05:00
Cort Buffington
897540243a Peer List Print & More Validation 2013-07-31 12:33:31 -05:00
Cort Buffington
8f8608cbfc Started adding conditionals to validate messages
for example: if we haven't yet received a peer list from the master, we
should not be processing keep-alives from peers.
2013-07-30 11:50:29 -05:00
Cort Buffington
2e0f29fc97 Peer Validation - In Progress
Mostly done.. must find a way to allow master registration and
reception of peer list BEFORE validating incoming messages to the peer
list -- chicken and egg problem. Easily solved, but needs an EFFICIENT
solution since EVERY PACKET will be passed through this test.
2013-07-30 10:52:10 -05:00
Cort Buffington
ca22654a13 Peer validation work 2013-07-29 21:12:12 -05:00
Cort Buffington
2d0c767c11 Begin adding valid peer and master checking… partial
Not yet completed, but done in a way to pass so the code works.
2013-07-29 21:06:25 -05:00
Cort Buffington
c1f6442f07 Standardized use of binascii for hex conversions
Had been using a mix of unhexlify/hexlify and a2b_hex/b2a_hex. I
settled on the later as it's the most descriptive to me.
2013-07-29 20:51:21 -05:00
Cort Buffington
7650e7cc4d Remove Cruft in Logging 2013-07-29 13:38:59 -05:00
Cort Buffington
724f9299cb Added IPSC Authentication Validation Function
We can now pass the auth key, and a packet to this function and get a
pass/fail (True/False) return.
2013-07-29 13:23:37 -05:00
Cort Buffington
7c6899e49f Clean up debug logging for peer lists
Fixed the peer-list printing function so that it signals there is no
peer list if we've not yet received one.
2013-07-28 22:33:14 -05:00
Cort Buffington
7518583e23 Moved peer-list processor to global scope
There was no reason for the IPSC class to contain the function for
processing a peer list. It makes the class more self-sustaining, but
the goal should be a *module* to handle connection maintenance. I moved
the peer list process, and built a mode decoder function from the
previos mode printing function, as well as added decoded mode items to
the data structure… and cleaned up the prining function so it doesn't
re-process the data.
2013-07-28 22:22:04 -05:00
Cort Buffington
8e7cdd7912 More naming cleanup
Making things read more easily.
2013-07-28 16:22:25 -05:00
Cort Buffington
c34357e10d Cleaned Up Several Items...
Mostly references to my_ipsc_config data structure items that are
commonly used. These received shortened names within the IPSC class…
also makes it easier to read, and should be self explanatory. Some
cruft also removed - object aliases that were no longer used.
2013-07-28 15:53:56 -05:00
Cort Buffington
8d115875f3 Implemented Keep-Alive Timers for Master & Peers
These have been open issues. They are mostly completed. Now, once a
master or peer is registered, keep-alives start, and run every
(configurable) time, unless (configurable) times are missed, and then
it de-registers the peer. The outstanding counter still needs work, but
the important parts are there.
2013-07-26 17:29:47 -05:00
Cort Buffington
819848d17c Revert "Not sure why this is needed"
This reverts commit c00627033e.
2013-07-22 21:44:53 -05:00
Cort Buffington
c00627033e Not sure why this is needed 2013-07-22 21:32:51 -05:00
Cort Buffington
fe7d44a2da Activated "ENABLED" Status Flag in Config
If the enabled setting for an IPSC is marked False, taht IPSC will not
be activated.
2013-07-20 22:20:27 -05:00
Cort Buffington
b8e3b3f8c9 Added network name to all logging lines 2013-07-20 21:53:45 -05:00
Cort Buffington
040492c2e2 Fixed errors in the sample config
I missed a few commas in it. They are there now
2013-07-20 18:13:15 -05:00
Cort Buffington
9eddcf762b Change Logging Status
Moved most info items into debug to make it less chatty
2013-07-20 15:41:22 -05:00
Cort Buffington
a99fa58a50 Lots 'O Comments, work on open issues
Work done on issues of timed actions for us to initiate relationships
with IPSC peers.

Tons of comments added so it likely actually makes sense to a reader
now.
2013-07-20 08:28:52 -05:00
Cort Buffington
d74261c5ac Data Type Cleanup
In the data structures, I had kinda been storing things randomly. In
preparing to address more of the issues, it was clear this needed (and
still does) cleaned up. Other than a few mods along the way, the goal
has been to minimize conversions while processing "real" in/out network
traffic, and do as much as possible one-time (such as the peer list),
or in formatting for output -- which is really mostly debugging and
will go away.
2013-07-15 12:04:48 -05:00
Cort Buffington
b8581c75eb Minor Wording Changes 2013-07-14 11:31:27 -05:00
Cort Buffington
bd5b0a074d Initial Uplaod of Re-Org'd Files 2013-07-11 19:45:09 -05:00
Cort Buffington
6aef3febc6 Service Flags Updated
Figured out several of the flags previously unknown, and corrected an
error: the bits for data call or voice call were transposed.
2013-07-10 16:21:36 -05:00
Cort Buffington
82d02104ae Adding more packet type information 2013-07-08 15:41:44 -05:00
Cort Buffington
4b91741de1 Add Message Types & Fix Timing
Added new datatypes (and changed the names on some that were figured
out). Fixed the master registration timing issue so that registrations
are attempted repeatedly until there is a reply, then keep-alives start.
2013-07-05 17:42:23 -05:00
Cort Buffington
4207a1c1de Addition of new packet types
0x61, 0x62, 0x9A -- unfortunately, the purpose of them is not yet know.
2013-07-03 14:48:30 -05:00
Adam Fast
3413dee576 Attempt to load configuration from a module my_ipsc_config.py to allow leaving your systems configured without editing the main Python source file - and as that file is expected to have IPs / keys that may not be intended for the public, tell git to ignore that file. 2013-06-28 23:38:28 -05:00
Adam Fast
1253c7f405 Convert to Python logging module for greater flexibility in where / how things are displayed. 2013-06-28 23:36:39 -05:00
Adam Fast
fec136d20e Standardize indentation with the rest of the module 2013-06-28 23:03:53 -05:00
Adam Fast
afa9a4b596 Use argparse to add a command line switch to only connect to a single network. 2013-06-27 18:17:52 -05:00
Cort Buffington
9828205557 Initializing Project 2013-06-27 16:15:54 -05:00