You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: msgtype.go
    path of file: ./repos/scan4all/vendor/github.com/jcmturner/gokrb5/v8/crypto/rfc4757
    
    the code of the file until where you have to start completion: package rfc4757

import "encoding/binary"

// UsageToMSMsgType converts Kerberos key usage numbers t
    
func UsageToMSMsgType(usage uint32) []byte {
	// Translate usage numbers to the Microsoft T numbers
	switch usage {
	case 3:
		usage = 8
	case 9:
		usage = 8
	case 23:
		usage = 13
	}
	// Now convert to bytes
	tb := make([]byte, 4) // We force an int32 input so we can't go over 4 bytes
	binary.PutUvarint(tb, uint64(usage))
	return tb
}