Implement getpeername syscall