Modified logging to prevent seg faults, functionalized socket, added signal handling, added daemon user conf opt