fix: added a mutex to write ops in the hid module

This commit is contained in:
evilsocket 2019-02-21 11:50:56 +01:00
commit d21f3b447a
No known key found for this signature in database
GPG key ID: 1564D7F30393A456
4 changed files with 11 additions and 0 deletions

View file

@ -81,6 +81,9 @@ func (mod *HIDRecon) prepInjection() (error, *network.HIDDevice, []*Command) {
}
func (mod *HIDRecon) doInjection() {
mod.writeLock.Lock()
defer mod.writeLock.Unlock()
err, dev, cmds := mod.prepInjection()
if err != nil {
mod.Error("%v", err)