bug fixes and features

fixed some bugs and added the ability to only intercept C2S or S2C
directions.