1258945Sroberto#ifndef MAIN_H
2258945Sroberto#define MAIN_H
3258945Sroberto
4280849Scy#include <stdio.h>
5258945Sroberto#include <isc/result.h>
6258945Sroberto#include <isc/net.h>
7258945Sroberto
8280849Scy#include <ntp.h>
9280849Scy#include <ntp_unixtime.h>
10280849Scy#include <ntp_stdlib.h>
11280849Scy#include <ntp_intres.h>
12280849Scy#include <ntp_debug.h>
13280849Scy#include <timevalops.h>
14280849Scy
15258945Sroberto#include <sntp-opts.h>
16258945Sroberto
17258945Sroberto#include "crypto.h"
18258945Sroberto
19280849Scyvoid	set_li_vn_mode(struct pkt *spkt, char leap, char version, char mode);
20280849Scyextern int sntp_main(int argc, char **argv, const char *);
21280849Scyint	generate_pkt(struct pkt *x_pkt, const struct timeval *tv_xmt,
22258945Sroberto				  int key_id, struct key *pkt_key);
23280849Scyint	handle_pkt(int rpktl, struct pkt *rpkt, sockaddr_u *host,
24280849Scy		   const char *hostname);
25280849Scyvoid	offset_calculation(struct pkt *rpkt, int rpktl,
26280849Scy			   struct timeval *tv_dst, double *offset,
27280849Scy			   double *precision, double *root_dispersion);
28280849Scyint	on_wire(struct addrinfo *host, struct addrinfo *bcastaddr);
29280849Scyint	set_time(double offset);
30258945Sroberto
31258945Sroberto#endif /* MAIN_H */
32