aboutsummaryrefslogtreecommitdiff
path: root/src/sensor/sensor.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/sensor/sensor.h')
-rw-r--r--src/sensor/sensor.h31
1 files changed, 27 insertions, 4 deletions
diff --git a/src/sensor/sensor.h b/src/sensor/sensor.h
index 0b8daaa2c..521f931ce 100644
--- a/src/sensor/sensor.h
+++ b/src/sensor/sensor.h
@@ -40,9 +40,9 @@ GNUNET_NETWORK_STRUCT_BEGIN
40 struct GNUNET_MessageHeader header; 40 struct GNUNET_MessageHeader header;
41 41
42 /** 42 /**
43 * Length of sensor name (name follows the struct) 43 * Length of sensor name. Allocated at position 0 after this struct.
44 */ 44 */
45 size_t name_len; 45 uint16_t name_len;
46 46
47 /** 47 /**
48 * First part of version number 48 * First part of version number
@@ -55,9 +55,32 @@ GNUNET_NETWORK_STRUCT_BEGIN
55 uint16_t version_minor; 55 uint16_t version_minor;
56 56
57 /** 57 /**
58 * Length of sensor description (description itself follows) 58 * Length of sensor description. Allocated at position 1 after this struct.
59 */ 59 */
60 size_t description_len; 60 uint16_t description_len;
61};
62
63/**
64 * A message sent to the sensor service to force an anomaly status on a sensor.
65 */
66struct ForceAnomalyMessage
67{
68
69 /**
70 * Message header
71 */
72 struct GNUNET_MessageHeader header;
73
74 /**
75 * Hash of the sensor name
76 */
77 struct GNUNET_HashCode sensor_name_hash;
78
79 /**
80 * New status
81 */
82 uint16_t anomalous;
83
61}; 84};
62 85
63GNUNET_NETWORK_STRUCT_END 86GNUNET_NETWORK_STRUCT_END