A Generalized Notion of Non-interference for Flow Security of Sequential and Concurrent Programs