Fix input signing bug, change params and update tests.