Add UST uid/gid contexts
authorMichael Jeanson <mjeanson@efficios.com>
Tue, 12 Feb 2019 16:51:55 +0000 (11:51 -0500)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Wed, 23 Oct 2019 20:35:53 +0000 (16:35 -0400)
Add the following userspace tracer context fields:
  - vuid
    Virtual real user ID: real user ID as seen from the point of view of
    the current user namespace

  - veuid
    Virtual effective user ID: effective user ID as seen from the point of
    view of the current user namespace

  - vsuid
    Virtual saved set-user ID: saved set-user ID as seen from the point of
    view of the current user namespace

  - vgid
    Virtual real group ID: real group ID as seen from the point of view of
    the current user namespace

  - vegid
    Virtual effective group ID: effective group ID as seen from the point of
    view of the current user namespace

  - vsgid
    Virtual saved set-group ID: saved set-group ID as seen from the point of
    view of the current user namespace

Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
src/bin/lttng-sessiond/save.c
src/bin/lttng-sessiond/trace-ust.c

index cb8a6b06047fc6191e949a6a3616ac9034611aaf..865775c8d838108c9691a6010183a8932a1a1abf 100644 (file)
@@ -404,6 +404,24 @@ const char *get_ust_context_type_string(
        case LTTNG_UST_CONTEXT_UTS_NS:
                context_type_string = config_event_context_uts_ns;
                break;
+       case LTTNG_UST_CONTEXT_VUID:
+               context_type_string = config_event_context_vuid;
+               break;
+       case LTTNG_UST_CONTEXT_VEUID:
+               context_type_string = config_event_context_veuid;
+               break;
+       case LTTNG_UST_CONTEXT_VSUID:
+               context_type_string = config_event_context_vsuid;
+               break;
+       case LTTNG_UST_CONTEXT_VGID:
+               context_type_string = config_event_context_vgid;
+               break;
+       case LTTNG_UST_CONTEXT_VEGID:
+               context_type_string = config_event_context_vegid;
+               break;
+       case LTTNG_UST_CONTEXT_VSGID:
+               context_type_string = config_event_context_vsgid;
+               break;
        case LTTNG_UST_CONTEXT_PERF_THREAD_COUNTER:
                /*
                 * Error, should not be stored in the XML, perf contexts
index e91102a6d7d6fa27c78b55cc3844eadcae8ac7d0..486b53d30c117b1be901b2d1ce7b134ca310cd5b 100644 (file)
@@ -585,6 +585,24 @@ int trace_ust_context_type_event_to_ust(
        case LTTNG_EVENT_CONTEXT_UTS_NS:
                utype = LTTNG_UST_CONTEXT_UTS_NS;
                break;
+       case LTTNG_EVENT_CONTEXT_VUID:
+               utype = LTTNG_UST_CONTEXT_VUID;
+               break;
+       case LTTNG_EVENT_CONTEXT_VEUID:
+               utype = LTTNG_UST_CONTEXT_VEUID;
+               break;
+       case LTTNG_EVENT_CONTEXT_VSUID:
+               utype = LTTNG_UST_CONTEXT_VSUID;
+               break;
+       case LTTNG_EVENT_CONTEXT_VGID:
+               utype = LTTNG_UST_CONTEXT_VGID;
+               break;
+       case LTTNG_EVENT_CONTEXT_VEGID:
+               utype = LTTNG_UST_CONTEXT_VEGID;
+               break;
+       case LTTNG_EVENT_CONTEXT_VSGID:
+               utype = LTTNG_UST_CONTEXT_VSGID;
+               break;
        default:
                utype = -1;
                break;
This page took 0.027477 seconds and 4 git commands to generate.