Lines Matching defs:icmp
1201 /* Do a sanity check on the packet for ICMP (v4). In nearly all cases, */
1203 /* The expected minimum size of an ICMP packet is very much dependent on */
1206 /* XXX - other ICMP sanity checks? */
1212 int minicmpsz = sizeof(struct icmp);
1213 icmphdr_t *icmp;
1228 icmp = fin->fin_dp;
1230 fin->fin_data[0] = *(u_short *)icmp;
1231 fin->fin_data[1] = icmp->icmp_id;
1233 switch (icmp->icmp_type)
1268 if (icmp->icmp_code == ICMP_UNREACH_NEEDFRAG) {
1269 if (icmp->icmp_nextmtu < softc->ipf_icmpminfragmtu) {
1271 DT3(ipf_fi_bad_icmp_nextmtu, fr_info_t *, fin, u_int, icmp->icmp_nextmtu, u_int, softc->ipf_icmpminfragmtu);
1287 * ICMP error packets should not be generated for IP
3104 * Should we return an ICMP packet to indicate error
3106 * WARNING: ICMP error packets AND TCP RST packets should
3148 * After the above so that ICMP unreachables and TCP RSTs get
4315 /* Returns: int - 1 if "icmp" is a valid reply to "ic" else 0. */
4317 /* ic(I) - ICMP information */
4318 /* icmp(I) - ICMP packet header */
4321 /* Check if the ICMP packet defined by the header pointed to by icmp is a */
4326 ipf_matchicmpqueryreply(int v, icmpinfo_t *ic, icmphdr_t *icmp, int rev)
4337 if ((!rev && (icmp->icmp_type == ictype)) ||
4338 (rev && (icmpreplytype4[ictype] == icmp->icmp_type))) {
4339 if (icmp->icmp_type != ICMP_ECHOREPLY)
4341 if (icmp->icmp_id == ic->ici_id)
4347 if ((!rev && (icmp->icmp_type == ictype)) ||
4348 (rev && (icmpreplytype6[ictype] == icmp->icmp_type))) {
4349 if (icmp->icmp_type != ICMP6_ECHO_REPLY)
4351 if (icmp->icmp_id == ic->ici_id)
6541 csump = &((struct icmp *)fin->fin_dp)->icmp_cksum;
9144 /* IPFilter. At present this just amounts to initialising some ICMP lookup */
9152 /* fill icmp reply type table */
9161 /* fill icmp reply type table */