Added signing. Only implementation is left for the server.