summaryrefslogtreecommitdiff
path: root/include
Commit message (Collapse)AuthorAgeFilesLines
* ipcpd: Add capability reportingdimitri staessens2017-04-271-0/+8
| | | | | | | | The IPCP will now report the DIF name and the hash value to the IRMd as a dif_info struct. This can later be extended to add further capability reporting. Some bugfixes in normal. Fixes #24
* lib: Add call to reserve blocks in rdrbuffdimitri staessens2017-04-263-20/+59
| | | | | | | This adds a call ipcp_sdb_reserve to reserve memory in the rdrbuff without directly writing to a flow. The ipcp_flow_del function was renamed to ipcp_sdb_release. The functions operating on sdbs are moved to their own header.
* lib: Remove dependency on installed headersSander Vrijders2017-04-243-10/+12
| | | | | | | The header ipcp.h was not installed systemwide, giving compile time errors when trying to compile external programs that use irm.h. ipcp.h also included hash.h, which exposes project interal functions. The enum was moved to ipcp.h to prevent this.
* ipcpd: Allow specifying the hash algorithm to usedimitri staessens2017-04-163-4/+19
| | | | Currently CRC32, MD5, and SHA3 (224, 256, 384 and 512 bit) are supported.
* include: Fix typo in endian.hdimitri staessens2017-04-161-1/+1
|
* lib: Add implementation for MD5 hashesdimitri staessens2017-04-162-2/+75
|
* lib: Fix minor things in sha3 implementationdimitri staessens2017-04-161-3/+3
|
* lib: Fix error in SWIG wrapperSander Vrijders2017-04-131-1/+3
| | | | This fixes an error in the SWIG wrapper.
* include: Add C++ directives in headersdimitri staessens2017-04-139-2/+79
| | | | Fixes #34
* include, lib: Rename ap_init/ap_finidimitri staessens2017-04-131-2/+2
| | | | Fixes #35
* Merged in dstaesse/ouroboros/be-hashes (pull request #479)dimitri staessens2017-04-1311-30/+214
|\ | | | | | | lib, ipcpd, irmd: Register hash instead of name
| * lib, ipcpd, irmd: Register hash instead of namedimitri staessens2017-04-1311-30/+214
| | | | | | | | | | | | | | | | | | All information passed over the IRMd/IPCP boundary for using IPC services (flow allocation, registration) is now hashed. This effectively fixes the shared namespace between DIFs and the IRMDs. This PR also fixes some API issues (adding const identifiers), shuffles the include headers a bit and some small bugs.
* | build: Add STATUS to message statementsSander Vrijders2017-04-121-2/+2
|/ | | | | | This adds the STATUS variable to the message() call in CMakeLists.txt in places where it was missing. This ensures that the message is printed to stdout instead of stderr.
* lib: Make timeout for flow allocation constdimitri staessens2017-04-101-5/+5
|
* build: Change compiler check output and update wrapSander Vrijders2017-04-071-1/+1
| | | | | | This removes some of the log messages spewed out during a check of a compiler flag. It also makes the SWIG compiler flag for C99 independent of the compiler.
* lib, irmd: Implement flow allocation timeoutdimitri staessens2017-04-061-2/+0
| | | | | | Setting the timeouts on flow_alloc and flow_accept will now work. This makes some changes to the UNIX sockets used for management communication between the APs, IRMd and IPCPs.
* ipcpd: Add dynamic threadpooling for IPCPsdimitri staessens2017-04-021-1/+5
|
* lib: Fix some issues in lockless rbuffdimitri staessens2017-04-011-1/+1
|
* lib: Lockless implementation of the rbuffdimitri staessens2017-04-011-0/+1
|
* irmd: Add dynamic threadpooldimitri staessens2017-04-011-3/+8
| | | | | | | | | | | This makes the IRMd add/remove worker threads dynamically. IRMD_TPM_TIMEOUT sets a timer in the threadpool manager for checking idle threads. Each time this timer expires, it will reduce the threadpool by one. IRMD_MIN_AV_THREADS is the minimum number of available worker threads. If the number of active threads goes under this threshold, the threadpool manager will create threads to get the number of threads to IRMD_MAX_AV_THREADS, unless IRMD_MAX_THREADS is reached.
* lib: Add a check if a bitmap ID is in usedimitri staessens2017-04-011-1/+4
|
* include: Fix indentation in fcntl.hdimitri staessens2017-04-011-9/+9
|
* lib: Revise flow allocation APIdimitri staessens2017-03-311-14/+9
| | | | | | The flow_alloc_res and flow_alloc_resp calls have been removed. The flow_alloc and flow_accept calls are now both blocking and take an additional timeout argument.
* ipcpd: normal: Fill in forwarding tableSander Vrijders2017-03-241-1/+3
| | | | | | The routing now takes the results of the routing table to fill in the forwarding table, by going through the neighbors and filling in the right fd.
* include: fflush stdout after printing a log msgdimitri staessens2017-03-221-0/+1
|
* Merge branch 'testing' into beSander Vrijders2017-03-211-2/+2
|\
| * ipcpd: local: Handle failed flow allocationSander Vrijders2017-03-211-3/+3
| | | | | | | | | | | | When the flow_req_arr returned a negative error, it was not handled correctly in the local IPCP, and an access was made into a table with a negative integer. This handles it correctly.
* | lib: Add queued SDUs when adding fd to flow_setdimitri staessens2017-03-211-0/+2
| | | | | | | | | | This solves some race conditions where packets arrive on a flow before it is added to a flow_set.
* | lib: Manage multiple flows with a single CDAP instancedimitri staessens2017-03-031-3/+8
| | | | | | | | | | | | | | | | You can now add multiple flows to a CDAP instance. This will simplify sending messages to different peers (e.g. for syncing the RIB). A request will now return an array of keys terminated by CDAP_KEY_INVALID. Removes the enum from the CDAP proto file to just take the opcode as an integer.
* | Change email addresses to ugent.beSander Vrijders2017-03-0329-47/+67
| | | | | | | | | | | | | | Our mailserver was migrated from intec.ugent.be to the central ugent.be emailserver. This PR updates the header files to reflect this change as well. Some header files were also homogenized if the parameters within the functions were badly aligned.
* | lib: Install cacep.h on installSander Vrijders2017-03-031-0/+1
| | | | | | | | | | cacep.h was not installed on install, but other applications may want to use it as well.
* | ipcpd: normal: Add connection managerSander Vrijders2017-03-021-5/+2
| | | | | | | | | | | | | | This adds the connection manager which allows the different AEs of the normal IPCP to register with it. An AE can then use the connection manager to allocate a flow to a neighbor, or to wait for a new connection from a neighbor.
* | lib: Split CACEP into request/response protocoldimitri staessens2017-02-281-6/+4
| |
* | lib: Split authentication from CACEPdimitri staessens2017-02-272-26/+16
| | | | | | | | | | | | | | By removing authentication as part of CACEP, all policies disappear. CACEP becomes a policy-free connection establishment protocol between Application Entities. Authentication can later be added cleanly as a pure policy function when needed.
* | lib: Remove application entity nameSander Vrijders2017-02-242-7/+2
| | | | | | | | | | The AE name should not be passed over the layer boundaries. If an application has more than one AE it should exchange this in CACEP.
* | Revise CACEP APIdimitri staessens2017-02-241-10/+11
| | | | | | | | | | | | The information passed to CACEP is split between the information about the connection and the information to be used during the authentication exchange.
* | lib: Exchange protocol info during CACEPdimitri staessens2017-02-212-0/+16
| | | | | | | | | | | | | | | | | | This exchanges a protocol name, a protocol version and concrete syntax for the protocol upon CACEP. For CDAP, only version 1 and GPB are supported. No lists for other supported versions or syntaxes are exchanged (but the proto file supports it). CACEP fails if there is a mismatch between the protocol names, version and syntax specified by the communicating parties.
* | lib: Revise CACEPdimitri staessens2017-02-202-13/+10
|/ | | | | | | | | Revises CACEP policies to stateless library calls. It provides two policies: an anonymous authentication policy that will generate random credentials for the peer, and a simple authentication policy that will return a name for the peer and an address. Changes the normal IPCP to use the updates API calls.
* ipcpd: Move RIB configuration to common headerdimitri staessens2017-02-171-6/+0
| | | | | Moves the definitions of paths in the RIB for the normal IPCP to a header ribconfig.h to avoid repetition.
* lib: Revise endian header and SHA3Sander Vrijders2017-02-161-112/+52
| | | | | | | | This revises the endian header to let the build time checks of endianness be performed by the standard libraries. We just check for the OS that is being used and provide the endian functions from OpenBSD to everyone. It also updates the SHA3 sources to use this new header. The byte order header is removed.
* ipcpd: Fix build on FreeBSDdimitri staessens2017-02-131-1/+3
| | | | | Use labs for absolute value of a long, and defines bswap_64 as the FreeBSD function bswap64.
* ipcpd: Increase threadpool sizeSander Vrijders2017-02-131-1/+1
| | | | | | This increases the threadpool size for the IPCP main loop. Starvation was happening due to a lot of back and forth interactions between the normal IPCPd and the IRMd.
* include: Use width in endian naming conventiondimitri staessens2017-02-121-16/+8
| | | | | ntohll and ntohl have been renamed ntoh64 and ntoh32, htonll and htonl have been renamed hton64 and hton32.
* irmd: Allow time for AP to call flow_accept()dimitri staessens2017-02-121-0/+1
| | | | | | | | When there is a burst of successive flow allocations for a certain name, each such request will block a thread in the IRMD for IRMD_REQ_ARR_TIMEOUT ms to allow the application some time to respond. This refactors some parts of the IRMd.
* ipcpd: Compare timestamp upon enrollmentdimitri staessens2017-02-111-6/+4
| | | | | | The enrollment procedure will ask for a timestamp of the IPCP it is enrolling with. It will (taking into account the RTT of the request) issue a warning if the offset is larger than RIB_WARN_TIME_OFFSET ms.
* cdap: Take void * for send operationsdimitri staessens2017-02-101-3/+3
| | | | This facilitates sending arbitrary variables over CDAP.
* include: Add header for endiannessdimitri staessens2017-02-102-0/+155
| | | | | | | | | This adds a header for dealing with endianness in ouroboros. It is extracted from the byte_order header in the library (which now includes this header). It also exposes the functions ntohl, ntohll, htonl and htonll, necessary for converting 32 and 64 bit values for storage and retrieval from the RIB (which should store multi-byte values in network byte order).
* ipcpd, lib: Report IPCP creation failuredimitri staessens2017-02-097-39/+50
| | | | | | | | The IPCP will now respond with an ipcp_create_r message when it fails, informing the IRMd. Also adds some const qualifiers in the public headers and fixes some formatting in dev.c.
* lib, ipcpd: Comply to pedantic C99Sander Vrijders2017-02-081-28/+22
| | | | | | With the changes in this commit Ouroboros will compile with the pedantic flag on when the standard is C99. The main problem was the used of unnamed structs and unions, which is C11.
* lib: Log to the logging systemdimitri staessens2017-02-081-34/+22
| | | | | | | | | | This removes the logfile and outputs log messages to the logging system. The creation of the logfiles (as well as the ap_init() call) were moved into ipcp_init() to simplify the IPCP creation and shutdown. Fixes #25 Fixes #27