Add Device mgmt functionality.
Migrate legacy socket lib as applications.