Dynamic distributed trust management scheme for the Internet of Things