libnetconf2  3.5.4
NETCONF server and client library in C.
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
Server communication

Once at least one session is established, an nc_pollsession structure should be created with nc_ps_new(), filled with the session using nc_ps_add_session() and finally polled with nc_ps_poll(). Based on the return value from the poll, further actions can be taken. More sessions can be polled at the same time and any requests received on the sessions are handled internally.

If an SSH NETCONF session asks for a new channel, you can accept this request with nc_ps_accept_ssh_channel() or nc_session_accept_ssh_channel() depending on the structure you want to use as the argument.

The server-side notifications are also supported. You can create a new notification with nc_server_notif_new() and send it via nc_server_notif_send() to subscribed clients. Keep in mind that the session you wish to send a notification on has to have at least one subscriber, see nc_session_inc_notif_status(). Currently, only notifications about certificate expiration are implemented, see nc_server_notif_cert_expiration_thread_start().

Functions List

Available in nc_server.h.