The ovm_ipv6_t
type is the OrchIDS type of IPv6 addresses.
Continue reading
Category Archives: Virtual machine
Extending the language
Imagine you want to add a new construction to the Orchids language. A simple way is to just add a new primitive. However, in some cases this is not enough. Imagine Orchids did not have multiplication. We might add it as a primitive, and name it mult
for example. However you would then be forced to write, say, $x = mult($y, $z)
to multiply $y
with $z
in Orchids signatures instead of the cosier $x = $y*$z
. Continue reading
Writing simple primitives
The language of Orchids includes several primitives, but you may want to add new ones.
The main primitives of Orchids are coded in lang.c
. Some others are provided by modules. Let us look at a simple example, that of the function int_from_str
, which converts a string such as "12"
to the corresponding integer (12 here). Continue reading
The ovm_extern_t type
The ovm_extern_t
type is a catch-all OrchIDS type, for all foreign data structures. Continue reading
The ovm_snmpoid_t type
The ovm_snmpoid_t
type is the OrchIDS type of SNMP object identifiers. Continue reading
The ovm_float_t type
The ovm_float_t
type is the OrchIDS incarnation of the data type double
of 64-bit floating point values. Continue reading
The ovm_regex_t type
The ovm_regex_t
type is the OrchIDS type of regular expression matchers. Continue reading
The ovm_timeval_t type
The ovm_timeval_t
type is the OrchIDS incarnation of the data type struct timeval
of times and durations. Continue reading
The ovm_ipv4_t type
The ovm_ipv4_t
type is the OrchIDS type of IPv4 addresses.
Continue reading
The ovm_ctime_t type
The ovm_ctime_t
type is the OrchIDS incarnation of the data type time_t
of times (not durations: durations are represented as machine integers, of type ovm_int_t
). Continue reading