Analysis and Enforcement of Properties in Software Systems