Skip to content
FajFs edited this page Mar 1, 2020 · 1 revision

Quick Description

The Userspace eBPF is a virtual machine that enables safe execution of code within a controlled environment. All plugins are using a combination of the functions below.

Available functions

The following functions are used by the virtual machine.

  • Specific API related
    • plugin_run_protoop
      • Execute protocol operations.
    • get_opaque_data
      • Retrieve a memory area shared by pluglets.
    • reserve_frames
      • Book the sending of QUIC frames
    • get_cnx
      • Get value in a context instance
    • set_cnx
      • Set value in a context instance
    • get_path
    • set_path
    • get_pkt_ctx
    • set_pkt_ctx
    • get_pkt
    • set_pkt
    • get_sack_item
    • set_sack_item
    • get_cnxid
    • set_cnxid
    • get_stream_head
    • set_stream_head
    • get_stream_data
    • get_crypto_context
    • set_crypto_context
    • get_ph
    • set_ph
    • cancel_head_reservation
  • Specific to picoquic
    • picoquic_reinsert_cnx_by_wake_time
    • picoquic_current_time
  • For memory
    • my_malloc
      • Provides the same functionality as malloc in c
    • my_free
      • Provides the same functionality as free in c
    • my_realloc
    • my_memcpy
    • my_memset
      • Provides the same functionality as memset in c
  • For time
    • clock_gettime
  • Network with Linux
    • getsockopt
    • setsockopt
    • socket
    • connect
    • send
    • inet_aton
    • socketpair
    • write
    • close
    • get_errno
    • my_htons
    • my_ntohs
    • strncmp
    • strlen
  • Logging
    • picoquic_has_booked_plugin_frames
  • Specific QUIC functions
    • picoquic_decode_frames_without_current_time
    • picoquic_varint_decode
    • picoquic_varint_encode
    • picoquic_create_random_cnx_id_for_cnx
    • picoquic_create_cnxid_reset_secret_for_cnx
    • picoquic_register_cnx_id_for_cnx
    • picoquic_create_path
    • picoquic_getaddrs
    • picoquic_compare_connection_id
    • picoquic_compare_addr
    • picoquic_parse_stream_header
    • picoquic_find_stream
    • picoquic_set_cnx_state
    • picoquic_frames_varint_decode
    • picoquic_record_pn_received
  • Function with reserved value. Don't override it.
    • picoquic_memory_bound_error
  • Other
    • queue_peek
    • picoquic_frame_fair_reserve
    • plugin_pluglet_exists
    • inet_ntop
    • strerror
    • memcmp
    • my_malloc_dbg
    • my_malloc_ex
    • my_free_dbg
    • dprintf
    • snprintf
    • lseek
    • ftruncate
    • strlen
    • snprintf_bytes
    • strncpy
    • inet_ntop
    • get_preq
    • set_preq
    • strcmp

Clone this wiki locally