Skip to content

Commit 0c69c52

Browse files
log preflight events (#37)
1 parent cdf7c51 commit 0c69c52

File tree

2 files changed

+11
-5
lines changed

2 files changed

+11
-5
lines changed

moroz/svc_preflight.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ func (mw logmw) Preflight(ctx context.Context, machineID string, p santa.Preflig
6666
_ = mw.logger.Log(
6767
"method", "Preflight",
6868
"machine_id", machineID,
69+
"preflight_payload", p,
6970
"err", err,
7071
"took", time.Since(begin),
7172
)

santa/santa.go

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,15 +37,20 @@ type Preflight struct {
3737

3838
// A PreflightPayload represents the request sent by a santa client to the sync server.
3939
type PreflightPayload struct {
40-
OSBuild string `json:"os_build"`
41-
SantaVersion string `json:"santa_version"`
40+
SerialNumber string `json:"serial_num"`
4241
Hostname string `json:"hostname"`
4342
OSVersion string `json:"os_version"`
44-
CertificateRuleCount int `json:"certificate_rule_count"`
43+
OSBuild string `json:"os_build"`
44+
ModelIdentifier string `json:"model_identifier"`
45+
SantaVersion string `json:"santa_version"`
46+
PrimaryUser string `json:"primary_user"`
4547
BinaryRuleCount int `json:"binary_rule_count"`
48+
CertificateRuleCount int `json:"certificate_rule_count"`
49+
CompilerRuleCount int `json:"compiler_rule_count"`
50+
TransitiveRuleCount int `json:"transitive_rule_count"`
51+
TeamIDRuleCount int `json:"teamid_rule_count"`
4652
ClientMode ClientMode `json:"client_mode"`
47-
SerialNumber string `json:"serial_num"`
48-
PrimaryUser string `json:"primary_user"`
53+
RequestCleanSync bool `json:"request_clean_sync"`
4954
}
5055

5156
// EventPayload represents derived metadata for events uploaded with the UploadEvent endpoint.

0 commit comments

Comments
 (0)