`nonce` should probably be either a labelled argument (most explicit for user code that needs to be clearly secure) or the last argument to this function. Nonce should never be curried as this would create insecure streams.