fixed security service (made non-transactional) and functional tests