Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/CyberInnovationHub-NLD/OpenSourceDataDiode
/ functions
Functions
144 in github.com/CyberInnovationHub-NLD/OpenSourceDataDiode
⨍
Functions
144
◇
Types & classes
46
↓ 38 callers
Method
add
(&self, value: u64)
statistics/statistics_handler/src/lib.rs:33
↓ 14 callers
Function
write_to_bip_buffer
This function is used to write to the bip_buffer using the supplied writer. # Arguments `writer` - The bipBufferWriter used to write to the bip_buffer
framework/bip_utils/src/lib.rs:23
↓ 10 callers
Method
send
(&self, producer: &mut Producer)
protocol_handlers/ph_kafka/tests/ph_kafka_integration_test.rs:131
↓ 8 callers
Method
get_and_reset
(&self)
statistics/statistics_handler/src/lib.rs:39
↓ 8 callers
Method
run
This function is used to start the UdpSender on a seperate thread. The joinhandle to this thread is returned. # Arguments `rec_addr` - The address of
framework/transport_udp/src/tx/udp_sender.rs:57
↓ 7 callers
Method
chain_unwrap
(self)
protocol_handlers/ph_kafka/src/errors.rs:23
↓ 7 callers
Method
get_data_clone
returns a clone of the data struct
statistics/statistics_handler/src/lib.rs:128
↓ 7 callers
Method
receive_data
This function fetches data from the socket. This data is then copied to the supplied buffer.
framework/socket_utils/src/socket_reader.rs:55
↓ 7 callers
Method
send_data
(&mut self, buffer: &mut [u8])
framework/socket_utils/src/socket_writer.rs:64
↓ 7 callers
Method
update_state
This function is used to change the state depending MessageType of the incoming packet.
framework/transport_udp/src/rx/inner_udp_receiver.rs:103
↓ 7 callers
Function
write_packet_header
This function is used to write the packet header to a given buffer. This buffer should contain at least HEADER_SIZE_BYTES of empty space in front of t
framework/transport_udp/src/tx/mod.rs:60
↓ 6 callers
Method
as_u8
Returns the byte value of a given MessageType.
framework/framework_constants/src/lib.rs:52
↓ 6 callers
Function
clean_unwrap
(res: Result<T>)
framework/transport_udp/src/errors.rs:18
↓ 6 callers
Method
load
(&self)
statistics/statistics_handler/src/lib.rs:36
↓ 6 callers
Function
read_from_bip_buffer
This function is used to read from the bip_buffer using the supplied reader. # Arguments `reader` - The bipBufferReader used to read from the bip_buff
framework/bip_utils/src/lib.rs:38
↓ 6 callers
Function
set_syslog
( from_host_sys_log: String, from_port_sys_log: String, to_host_sys_log: String, to_port_sys_l
protocol_handlers/ph_mock_handler/src/lib.rs:18
↓ 5 callers
Function
set_syslog
Setting syslog with a specific log level and processname. The logging is sent with UDP
framework/logging/src/lib.rs:25
↓ 5 callers
Function
wait_for_data
Wait for the given amount of bytes to be available for reading in the bip_buffer. # Arguments `reader` - The bipBufferReader used to read from the bip
framework/bip_utils/src/lib.rs:70
↓ 4 callers
Method
chain_unwrap
(self)
protocol_handlers/ph_udp/src/errors.rs:23
↓ 4 callers
Function
get_element_length
Function used to get the element length field from the bip_buffer. The element length is consumed from the buffer by calling this function. # Argument
framework/bip_utils/src/lib.rs:56
↓ 4 callers
Method
stop
Stops the SocketReader. Calls Shutdown::Both on the underlying stream.
framework/socket_utils/src/socket_reader.rs:75
↓ 3 callers
Method
chain_unwrap
(self)
filters/filter/src/errors.rs:23
↓ 3 callers
Function
read_handler
Convert a handler from a TOML file to a handler struct. `type` and `open_udp_port` are specials cases and needed in the configuration in osdd. All oth
framework/osdd/src/read_toml.rs:114
↓ 3 callers
Method
run
(&self)
protocol_handlers/ph_mock_handler/src/bin/ph_mock_egress.rs:36
↓ 3 callers
Method
run
(&self)
protocol_handlers/ph_kafka/tests/ph_kafka_integration_test.rs:262
↓ 2 callers
Method
chain_unwrap
(self)
framework/osdd/src/errors.rs:24
↓ 2 callers
Method
handle_data_first_message
This function is used to handle a message that has the DataFirst MessageType.
framework/transport_udp/src/rx/inner_udp_receiver.rs:142
↓ 2 callers
Method
log_config_info
This function is used to log the complete configuration of the UdpReceiver.
framework/transport_udp/src/rx/rx_arguments.rs:84
↓ 2 callers
Function
read_packet_header
This function is used to read the information contained in the packet header of a received UDP packet. All packet information is placed inside a Packe
framework/transport_udp/src/rx/mod.rs:57
↓ 2 callers
Function
send_data
This function is used to send the data contained in `buffer` using `socket`. When the packet is succesfully sent, the sequence number is incremented b
framework/transport_udp/src/tx/mod.rs:32
↓ 1 callers
Function
assert_on_byte_array
asserts if the given buffer equals the buffer read from the bip_buffer.
framework/bip_utils/src/lib.rs:103
↓ 1 callers
Function
assign_sockets
( handlers_config: &mut Vec<Handler>, process1: &str, process2: &str, chain_name: &str, )
framework/osdd/src/lib.rs:238
↓ 1 callers
Function
check_for_packetloss
Packetloss is checked using the sequence number of the incoming packet. This sequence number should match the expected sequence number. If it doesn't
framework/transport_udp/src/rx/mod.rs:82
↓ 1 callers
Method
combine_and_write_to_bip
This function is used to combine all packets that belong to one set of data. The combined messages are written to the BipBuffer.
framework/transport_udp/src/rx/inner_udp_receiver.rs:206
↓ 1 callers
Function
command_socket_path_transport_protocol
(handler: &Handler, command: &mut Command)
framework/osdd/src/lib.rs:279
↓ 1 callers
Function
command_socket_paths_filter
(handler: &Handler, command: &mut Command)
framework/osdd/src/lib.rs:292
↓ 1 callers
Method
create_command
Create Docker command from a handler
framework/osdd/src/lib.rs:102
↓ 1 callers
Function
create_commands_all_handlers
Creates docker commands of the given handlers
framework/osdd/src/lib.rs:190
↓ 1 callers
Function
create_send_buffer
()
framework/transport_udp/tests/receiver_test.rs:61
↓ 1 callers
Function
create_stream
(path: &str)
framework/socket_utils/src/buffered_socket_writer.rs:82
↓ 1 callers
Function
create_test_buffers
returns a vector of multiple Vec<u8>
framework/bip_utils/src/lib.rs:116
↓ 1 callers
Method
deserialize_incoming_data_and_send_to_kafka
Give a u8 array, deserialize and send it to kafka # Arguments `bip_reader` - The BipBufferReader used to get data from the bip_buffer.
protocol_handlers/ph_kafka/src/producer.rs:77
↓ 1 callers
Method
fill_pipeline
(&self, pipeline: &mut Pipeline)
statistics/statistics_handler/src/lib.rs:70
↓ 1 callers
Function
filter
This filter checks for the first bytes of the incoming data. If it matches the configured "word_to_filter" then it drops the data. If the data is corr
filters/filter/src/bin/filter.rs:46
↓ 1 callers
Function
filtering
Check for the first bytes of a kafka message. If it matches the word_to_filter then it drops the data. Else it is written to the bipbuffer.
filters/filter/src/lib.rs:31
↓ 1 callers
Method
get
(&self)
statistics/statistics_handler/src/lib.rs:51
↓ 1 callers
Method
get_data_from_bipbuffer_and_send_data_to_kafka
Reads data from the bipbuffer and send it to kafka # Arguments `bip_reader` - The BipBufferReader used to get data from the bip_buffer.
protocol_handlers/ph_kafka/src/producer.rs:62
↓ 1 callers
Method
get_kafka_data_send_bip_buffer
Get data from the kafka server and send it to bipbuffer Calculcates message behind after every poll # Arguments `bip_writer` - The BipBufferWriter use
protocol_handlers/ph_kafka/src/consumer.rs:74
↓ 1 callers
Method
handle_data_message
This function is used to handle a message that has the Data MessageType.
framework/transport_udp/src/rx/inner_udp_receiver.rs:167
↓ 1 callers
Method
handle_heartbeat_message
This function is used to handle a message that has the Heartbeat MessageType.
framework/transport_udp/src/rx/inner_udp_receiver.rs:185
↓ 1 callers
Function
handle_processes
Starts processes from the given commands
framework/osdd/src/docker_runner.rs:20
↓ 1 callers
Method
handle_shutdown_message
This function is used to handle a message that has the ShutDown MessageType.
framework/transport_udp/src/rx/inner_udp_receiver.rs:200
↓ 1 callers
Method
handle_startup_message
This function is used to handle a message that has the StartUp MessageType.
framework/transport_udp/src/rx/inner_udp_receiver.rs:191
↓ 1 callers
Function
init_socket
This function is used to initialize the socket. It sets the BroadCast flag.
framework/transport_udp/src/tx/udp_sender.rs:92
↓ 1 callers
Function
inner_kafka_ingress
()
protocol_handlers/ph_kafka/src/bin/ph_kafka_ingress.rs:81
↓ 1 callers
Function
inner_udp_ingress
This handler is for udp packets in the ingress network it receive the udp packets and send it to the transport via a unix domain socket. in the egress
protocol_handlers/ph_udp/src/bin/ph_udp_ingress.rs:72
↓ 1 callers
Function
kafka_egress
()
protocol_handlers/ph_kafka/src/bin/ph_kafka_egress.rs:48
↓ 1 callers
Function
mutiplex
(stats_port: u16, stats_servers_string: Vec<String>)
framework/osdd/src/udp_multiplexer_stats.rs:30
↓ 1 callers
Function
osdd
This function starts the open source data diode. It loads the configuration from a TOML file. It starts a UDP multiplexer for statitics. It create and
framework/osdd/src/bin/osdd.rs:66
↓ 1 callers
Function
outer_kafka_ingress
()
protocol_handlers/ph_kafka/src/bin/ph_kafka_ingress.rs:47
↓ 1 callers
Function
outer_udp_egress
()
protocol_handlers/ph_udp/src/bin/ph_udp_egress.rs:44
↓ 1 callers
Function
outer_udp_ingress
()
protocol_handlers/ph_udp/src/bin/ph_udp_ingress.rs:45
↓ 1 callers
Method
poll_kafka
Poll the kafka server and send it to bipbuffer Calculcates message behind after every poll # Arguments `bip_writer` - The BipBufferWriter used to send
protocol_handlers/ph_kafka/src/consumer.rs:103
↓ 1 callers
Function
read_toml
Convert TOML file to settings, chains and handlers. println errors because logging is not initialized yet.
framework/osdd/src/read_toml.rs:35
↓ 1 callers
Method
receive
(&self, consumer: &mut Consumer, topic: String)
protocol_handlers/ph_kafka/tests/ph_kafka_integration_test.rs:148
↓ 1 callers
Function
receive_packet
This function is used to receive a UDP packet on the given socket. The received data is placed in the supplied buffer. # Arguments `socket` - The UdpS
framework/transport_udp/src/rx/mod.rs:37
↓ 1 callers
Method
replace_topic
Replace the topic as it is given in command args # Arguments `topic` - input topic. # Return 'String' - Topic name, if was in give input list it is re
protocol_handlers/ph_kafka/src/producer.rs:111
↓ 1 callers
Function
run
Receives all the stats form the handlers and send it to multiple addresses
framework/osdd/src/udp_multiplexer_stats.rs:22
↓ 1 callers
Method
run
(&self)
protocol_handlers/ph_mock_handler/src/bin/ph_mock_ingress.rs:36
↓ 1 callers
Function
send_shutdown_messages
This function is used to send packets with MessageType::ShutDown to the UdpReceiver.
framework/transport_udp/src/tx/special_message.rs:35
↓ 1 callers
Function
send_single_large_message
(writer: &mut BipBufferWriter)
framework/transport_udp/src/bin/transport_udp_send_test.rs:78
↓ 1 callers
Function
send_startup_messages
This function is used to send packets with MessageType::StartUp to the UdpReceiver.
framework/transport_udp/src/tx/special_message.rs:22
↓ 1 callers
Function
serialize_between_bip_buffers
Read data from the bipbuffer, serialize_packet and send it to another bipbuffer # Arguments `bip_reader` - The BipBufferWriter used to get data from t
protocol_handlers/ph_kafka/src/consumer.rs:147
↓ 1 callers
Method
serialize_packet
(&self, buf: &mut [u8])
protocol_handlers/ph_kafka/src/lib.rs:50
↓ 1 callers
Method
set
(&self, value: u64)
statistics/statistics_handler/src/lib.rs:48
↓ 1 callers
Method
set_custom_gauge
(&self, number: u64)
statistics/statistics_handler/src/lib.rs:85
↓ 1 callers
Function
setup_consumer
Setup a kafka consumer # Arguments `topic` - Topic name `host` - Host of the kafka server `port` - Server port of the kafka server # Returns `Consumer
protocol_handlers/ph_kafka/src/bin/ph_kafka_test_consumer.rs:136
↓ 1 callers
Function
setup_consumer
(topic: &str, host: &String, port: u16)
protocol_handlers/ph_kafka/tests/ph_kafka_integration_test.rs:234
↓ 1 callers
Function
split_and_send_data
This function is used to split the data read from a bip_buffer. The data is split into packets that can be sent over UDP(payload < 65507 bytes)
framework/transport_udp/src/tx/message_split.rs:27
↓ 1 callers
Function
split_and_send_full_messages
( socket: &UdpSocket, remaining_messages: &mut u16, element_buffer: &mut [u8], sequence_number
framework/transport_udp/src/tx/message_split.rs:54
↓ 1 callers
Function
start_sending_test_data
(mut writer: BipBufferWriter)
framework/transport_udp/src/bin/transport_udp_send_test.rs:62
↓ 1 callers
Function
statistics_inner_thread
( is_running: Arc<AtomicBool>, addr: String, prefix: String, data: Arc<dyn StatisticData + Sen
statistics/statistics_handler/src/lib.rs:184
↓ 1 callers
Method
stop
(&self)
protocol_handlers/ph_mock_handler/src/bin/ph_mock_ingress.rs:57
↓ 1 callers
Method
stop
(&self)
protocol_handlers/ph_mock_handler/src/bin/ph_mock_egress.rs:56
↓ 1 callers
Method
stop_and_check
(&self, test_data: Vec<(usize, usize)>)
protocol_handlers/ph_kafka/tests/ph_kafka_integration_test.rs:360
↓ 1 callers
Function
udp_receive
The program will start multiple threads: receiver_thread - The thread used by the UdpReceiver struct. statistics_thread - The thread used by the Stati
framework/transport_udp/src/bin/transport_udp_receive.rs:53
↓ 1 callers
Function
udp_send
The program will start multiple threads: sender_thread - The thread used by the UdpSender struct. statistics_thread - The thread used by the Statistic
framework/transport_udp/src/bin/transport_udp_send.rs:53
↓ 1 callers
Function
udp_sender_thread
( socket: UdpSocket, receiver_addr: String, should_stop: Arc<AtomicBool>, reader_mutex: Arc<Mu
framework/transport_udp/src/tx/udp_sender.rs:103
↓ 1 callers
Method
update_in_stats
This function will update the in_bytes and in_packets counter of the statistics struct.
framework/transport_udp/src/rx/inner_udp_receiver.rs:237
Function
_send_heartbeat_message
This function is used to send packets with MessageType::HeartBeat to the UdpReceiver.
framework/transport_udp/src/tx/special_message.rs:47
Function
_send_small_messages
(writer: &mut BipBufferWriter)
framework/transport_udp/src/bin/transport_udp_send_test.rs:68
Method
add_custom_counter
(&self, number: u64)
statistics/statistics_handler/src/lib.rs:93
Method
deserialize_packet
(buf: &[u8])
protocol_handlers/ph_kafka/src/lib.rs:60
Method
from_u8
Returns the MessageType for a given byte value. When no MessageType exists for the given byte value, MessageType::DataFirst is returned. # Arguments `
framework/framework_constants/src/lib.rs:62
Function
kafka_integration_test
()
protocol_handlers/ph_kafka/tests/ph_kafka_integration_test.rs:34
Method
log_config_info
This function is used to log the complete configuration of the UdpSender.
framework/transport_udp/src/tx/tx_arguments.rs:104
Function
main
()
framework/transport_udp/src/bin/transport_udp_receive.rs:30
Function
main
()
framework/transport_udp/src/bin/transport_udp_send.rs:30
Function
main
()
framework/transport_udp/src/bin/transport_udp_send_test.rs:28
Function
main
()
framework/osdd/src/bin/osdd.rs:35
next →
1–100 of 144, ranked by callers