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: pivots.go
    path of file: ./repos/sliver/server/core
    
    the code of the file until where you have to start completion: package core

/*
	Sliver Implant Framework
	Copyright (C) 2022  Bishop Fox

	This program is free software: you can redistribute it and/or modify

    
func (p *Pivot) Start() {
	go func() {
		defer func() {
			coreLog.Debugf("pivot session %s send loop closing (origin id: %d)", p.ID, p.OriginID)
		}()
		for envelope := range p.ImplantConn.Send {
			envelopeData, err := proto.Marshal(envelope)
			if err != nil {
				coreLog.Errorf("failed to marshal envelope: %v", err)
				continue
			}
			ciphertext, err := p.CipherCtx.Encrypt(envelopeData)
			if err != nil {
				coreLog.Errorf("failed to encrypt envelope: %v", err)
				continue
			}
			peerEnvelopeData, _ := proto.Marshal(&sliverpb.PivotPeerEnvelope{
				Type:  envelope.Type,
				Peers: p.Peers,
				Data:  ciphertext,
			})
			if err != nil {
				coreLog.Errorf("failed to wrap pivot peer envelope: %v", err)
				continue
			}
			p.ImmediateImplantConn.Send <- &sliverpb.Envelope{
				Type: sliverpb.MsgPivotPeerEnvelope,
				Data: peerEnvelopeData,
			}
		}
	}()
}