MCPcopy Create free account
hub / github.com/F-Stack/f-stack / ng_mppc_reset_req

Function ng_mppc_reset_req

freebsd/netgraph/ng_mppc.c:841–856  ·  view source on GitHub ↗

* The peer has sent us a CCP ResetRequest, so reset our transmit state. */

Source from the content-addressed store, hash-verified

839 * The peer has sent us a CCP ResetRequest, so reset our transmit state.
840 */
841static void
842ng_mppc_reset_req(node_p node)
843{
844 const priv_p priv = NG_NODE_PRIVATE(node);
845 struct ng_mppc_dir *const d = &priv->xmit;
846
847#ifdef NETGRAPH_MPPC_COMPRESSION
848 if (d->history != NULL)
849 MPPC_InitCompressionHistory(d->history);
850#endif
851#ifdef NETGRAPH_MPPC_ENCRYPTION
852 if ((d->cfg.bits & MPPE_STATELESS) == 0)
853 rc4_init(&d->rc4, d->key, KEYLEN(d->cfg.bits));
854#endif
855 d->flushed = 1;
856}
857
858#ifdef NETGRAPH_MPPC_ENCRYPTION
859/*

Callers 1

ng_mppc_rcvmsgFunction · 0.85

Calls 2

rc4_initFunction · 0.85

Tested by

no test coverage detected