JD Strong
04/12/2023, 6:45 PMZachary
04/12/2023, 7:48 PMHello_There
04/12/2023, 8:39 PMHello_There
04/12/2023, 8:43 PMMike S.
04/12/2023, 9:58 PMLuke Heath
04/12/2023, 10:15 PMVlad Previn
04/13/2023, 5:19 AMJD Strong
04/13/2023, 4:00 PMGlen
04/13/2023, 5:00 PMJason Roberts
04/13/2023, 6:32 PMMike S.
04/14/2023, 7:51 PMShiji Zhou
04/15/2023, 12:48 AMShiji Zhou
04/15/2023, 2:29 AMLabelQueriesForHost
method in server/datastore/mysql/labels.go
, there is a SQL query to get label queries for given host :
query := `SELECT id, query FROM labels WHERE platform = ? OR platform = '' AND label_membership_type = ?`
rows, err = ds.reader.QueryContext(ctx, query, platform, fleet.LabelMembershipTypeDynamic)
Considering that MySQL AND
operator takes precedence over the OR
operator, the query is the same as:
SELECT id, query FROM labels WHERE platform = ? OR (platform = '' AND label_membership_type = ?);
With this statement, a label query will be returned if the host's platform matches label's platform, even if the label's label_membership_type is "manual"
instead of "dynamic"
. However, a "manual" label is populated manually without the execution of a label query, so it is meaningless to return label queries for a manual label. Then I would suppose the query should look like:
`SELECT id, query FROM labels WHERE (platform = ? OR platform = '') AND label_membership_type = ?`
Which instead means that it only gets dynamic
label queries if the label's platform matches the host's or the label's platform is "all platforms"
I really appreciate it if someone could correct my misunderstandings, or confirm that there are some problems here.🤝Zapier
04/17/2023, 5:39 PMThiago Cruz
04/17/2023, 10:04 PM[windows with Orbit] --(https)--> [NGINX] --(proxy_pass)--> [FleetDM]
Everything is working fine, but I'm receiving this error message:
==> /var/log/nginx/fleet_ssl_error.log <==
2023/04/17 18:56:11 [crit] 206522#206522: *850 SSL_read() failed (SSL: error:0A000126:SSL routines::unexpected eof while reading) while keepalive, client: 192.168.0.33, server: 0.0.0.0:443
Should be expected a EOF from Orbit or is there some misconfiguration?Jesse Mundis
04/18/2023, 12:16 AMJincheng Yin
04/18/2023, 9:37 AMOjas
04/18/2023, 10:29 AMJames Konderla
04/18/2023, 5:01 PMJason Lewis
04/18/2023, 5:42 PMNemanja
04/19/2023, 7:06 AMVlad Previn
04/19/2023, 11:46 AMArsenio
04/19/2023, 3:28 PM*Compatible with:Estimated compatiblity based onthe tables used in the query.*No platforms (check your query for a possible syntax error)
SELECT
path
json_extract(path, '$.displayName') as displayName,
FROM
file
WHERE
path LIKE '%/%/.vscode/extensions/%/package.json'
AND type = 'regular';
Federico Alliani
04/20/2023, 6:39 PMKeith Swagler
04/20/2023, 6:56 PMwennan.he
04/20/2023, 11:55 PMYounes Boulfred
04/21/2023, 12:37 PMArsenio
04/21/2023, 2:31 PMfrederick ferby
04/21/2023, 3:31 PMZapier
04/22/2023, 3:25 PM