func addFileInternalInformation(dst []byte, fi Stat) []byte {
	return dst[8:]
}
[MS-FSCC].pdf 2.4.20 page 134
package smb2
import (
	"bytes"
	"encoding/binary"
	"fmt"
	"io"
	"log"
	"os"
	"strings"
	"time"
)
type fileInfo struct {
	isDir       bool
	dentries    []Stat
	nEnumerated int
	name        string
}
type Session struct {
	id uint64  
	treesById   map[uint32]Tree
	treesByName map[string]Tree
	openedFiles map[GUID]*fileInfo
}
func NewSession() *Session {
	return &Session{
		id:          uint64(time.Now().UnixNano()),
		treesById:   make(map[uint32]Tree),
		treesByName: make(map[string]Tree),
		openedFiles: make(map[GUID]*fileInfo),
	}
}
func (session *Session) addTrees(trees []Tree) {
	for _, p := range trees {
		session.treesById[p.Id()] = p
		session.treesByName[p.Name()] = p
	}
}
func addFileAccessInformation(dst []byte, fi Stat) []byte {
	binary.LittleEndian.PutUint32(dst, GENERIC_ALL)  
	return dst[4:]
}
func toFileAttributes(fi Stat) uint32 {
	var fileAttributes uint32
	if fi.IsDir() {
		fileAttributes |= FILE_ATTRIBUTE_DIRECTORY
	}
	if fi.IsReadOnly() {
		fileAttributes |= FILE_ATTRIBUTE_READONLY
	}
	return fileAttributes
}
func addFileBasicInformation(dst []byte, fi Stat) []byte {
	mtime := uint64(timeToFiletime(fi.ModTime()))
	atime := uint64(0)  
	binary.LittleEndian.PutUint64(dst, mtime)       
	binary.LittleEndian.PutUint64(dst[8:], atime)   
	binary.LittleEndian.PutUint64(dst[16:], mtime)  
	binary.LittleEndian.PutUint64(dst[24:], mtime)  
	binary.LittleEndian.PutUint32(dst[32:], toFileAttributes(fi))
	return dst[40:]
}
func addFileStandardInformation(dst []byte, fi Stat) []byte {
	binary.LittleEndian.PutUint64(dst, 1024*1024)              
	binary.LittleEndian.PutUint64(dst[8:], uint64(fi.Size()))  
	binary.LittleEndian.PutUint32(dst[16:], 1)                 
	if fi.IsDir() {
		dst[21] = 1
	}
	return dst[24:]
}