2 #include <event2/event.h>
15 TRPC_INSTANCE *trpc_new (TALLOC_CTX *mem_ctx)
17 return talloc_zero(mem_ctx, TRPC_INSTANCE);
20 void trpc_free (TRPC_INSTANCE *trpc)
26 /* Connect to a TRP server */
27 int trpc_open_connection (TRPC_INSTANCE *trpc,
34 unsigned int use_port = 0;
41 tr_debug("trpc_open_connection: opening GSS connection to %s:%d", server, use_port);
42 err = gsscon_connect(server, use_port, "trustrouter", &conn, gssctx);
51 /* simple function, based on tidc_send_req */
52 int trpc_send_msg (TRPC_INSTANCE *trpc,
55 const char *msg_content,
64 /* Send the request over the connection */
65 if (err = gsscon_write_encrypted_token (conn,
68 strlen(msg_content))) {
69 tr_err( "trpc_send_msg: Error sending message over connection.\n");