Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

util.go 394B

1234567891011121314
  1. // Copyright 2020 The Gitea Authors. All rights reserved.
  2. // SPDX-License-Identifier: MIT
  3. package proxyprotocol
  4. import "io"
  5. var localHeader = append(v2Prefix, '\x20', '\x00', '\x00', '\x00', '\x00')
  6. // WriteLocalHeader will write the ProxyProtocol Header for a local connection to the provided writer
  7. func WriteLocalHeader(w io.Writer) error {
  8. _, err := w.Write(localHeader)
  9. return err
  10. }