added root user support (may need work and security testing)