Added context and network provider interfaces and refactored Rule classes to eliminate exposure of sensitive parameters.