MCPcopy Create free account
hub / github.com/Maikefee/Windows-Persistence-Tool / copyFile

Function copyFile

main.go:175–190  ·  view source on GitHub ↗
(src, dst string)

Source from the content-addressed store, hash-verified

173}
174
175func copyFile(src, dst string) error {
176 srcFile, err := os.Open(src)
177 if err != nil {
178 return err
179 }
180 defer srcFile.Close()
181
182 dstFile, err := os.Create(dst)
183 if err != nil {
184 return err
185 }
186 defer dstFile.Close()
187
188 _, err = dstFile.ReadFrom(srcFile)
189 return err
190}
191
192func executeCommand(cmd string) (string, error) {
193 // 这里应该实现命令执行逻辑

Callers 1

startupBackdoorFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected