added some basic caller id-based permissions; misc other cleanups