The snonce function will just copy the nonce value from snonce global variable. This lets us avoid multiple functions that do essentially the same thing.