code: func (cs *Server) handleNonce(w http.ResponseWriter, r *http.Request) {
  	if r.Method != "GET" {
  		http.Error(w, "not a GET", http.StatusMethodNotAllowed)
  		return
  	}
  
  	mac := hmac.New(sha256.New, cs.keyHMAC)
  	message := fmt.Sprintf("%d", time.Now().Unix())
  	mac.Write([]byte(message))
  	messageHash := string(mac.Sum(nil))
  	nonce := fmt.Sprintf("%s-%x", message, messageHash)
  	if _, err := io.Copy(w, strings.NewReader(nonce)); err != nil {
  		log.Printf("error sending nonce: %v", err)
  		return
  	}
  }
docs: // handleNonce replies with a nonce. The nonce format is:
  // message-HexOf(HMAC(message)), where message is the current unix time in seconds.