]> git.proxmox.com Git - qemu.git/blob - slirp/ip_input.c
slirp: Drop dead code
[qemu.git] / slirp / ip_input.c
1 /*
2 * Copyright (c) 1982, 1986, 1988, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright
11 * notice, this list of conditions and the following disclaimer in the
12 * documentation and/or other materials provided with the distribution.
13 * 3. Neither the name of the University nor the names of its contributors
14 * may be used to endorse or promote products derived from this software
15 * without specific prior written permission.
16 *
17 * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
18 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
20 * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
21 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
22 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
23 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
24 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27 * SUCH DAMAGE.
28 *
29 * @(#)ip_input.c 8.2 (Berkeley) 1/4/94
30 * ip_input.c,v 1.11 1994/11/16 10:17:08 jkh Exp
31 */
32
33 /*
34 * Changes and additions relating to SLiRP are
35 * Copyright (c) 1995 Danny Gasparovski.
36 *
37 * Please read the file COPYRIGHT for the
38 * terms and conditions of the copyright.
39 */
40
41 #include <slirp.h>
42 #include <osdep.h>
43 #include "ip_icmp.h"
44
45 #ifdef LOG_ENABLED
46 struct ipstat ipstat;
47 #endif
48
49 struct ipq ipq;
50
51 static struct ip *ip_reass(register struct ip *ip,
52 register struct ipq *fp);
53 static void ip_freef(struct ipq *fp);
54 static void ip_enq(register struct ipasfrag *p,
55 register struct ipasfrag *prev);
56 static void ip_deq(register struct ipasfrag *p);
57
58 /*
59 * IP initialization: fill in IP protocol switch table.
60 * All protocols not implemented in kernel go to raw IP protocol handler.
61 */
62 void
63 ip_init(void)
64 {
65 ipq.ip_link.next = ipq.ip_link.prev = &ipq.ip_link;
66 ip_id = tt.tv_sec & 0xffff;
67 udp_init();
68 tcp_init();
69 }
70
71 /*
72 * Ip input routine. Checksum and byte swap header. If fragmented
73 * try to reassemble. Process options. Pass to next level.
74 */
75 void
76 ip_input(struct mbuf *m)
77 {
78 register struct ip *ip;
79 int hlen;
80
81 DEBUG_CALL("ip_input");
82 DEBUG_ARG("m = %lx", (long)m);
83 DEBUG_ARG("m_len = %d", m->m_len);
84
85 STAT(ipstat.ips_total++);
86
87 if (m->m_len < sizeof (struct ip)) {
88 STAT(ipstat.ips_toosmall++);
89 return;
90 }
91
92 ip = mtod(m, struct ip *);
93
94 if (ip->ip_v != IPVERSION) {
95 STAT(ipstat.ips_badvers++);
96 goto bad;
97 }
98
99 hlen = ip->ip_hl << 2;
100 if (hlen<sizeof(struct ip ) || hlen>m->m_len) {/* min header length */
101 STAT(ipstat.ips_badhlen++); /* or packet too short */
102 goto bad;
103 }
104
105 /* keep ip header intact for ICMP reply
106 * ip->ip_sum = cksum(m, hlen);
107 * if (ip->ip_sum) {
108 */
109 if(cksum(m,hlen)) {
110 STAT(ipstat.ips_badsum++);
111 goto bad;
112 }
113
114 /*
115 * Convert fields to host representation.
116 */
117 NTOHS(ip->ip_len);
118 if (ip->ip_len < hlen) {
119 STAT(ipstat.ips_badlen++);
120 goto bad;
121 }
122 NTOHS(ip->ip_id);
123 NTOHS(ip->ip_off);
124
125 /*
126 * Check that the amount of data in the buffers
127 * is as at least much as the IP header would have us expect.
128 * Trim mbufs if longer than we expect.
129 * Drop packet if shorter than we expect.
130 */
131 if (m->m_len < ip->ip_len) {
132 STAT(ipstat.ips_tooshort++);
133 goto bad;
134 }
135
136 if (slirp_restrict) {
137 if ((ip->ip_dst.s_addr & vnetwork_mask.s_addr) ==
138 vnetwork_addr.s_addr) {
139 if (ip->ip_dst.s_addr == 0xffffffff && ip->ip_p != IPPROTO_UDP)
140 goto bad;
141 } else {
142 struct ex_list *ex_ptr;
143
144 if ((ip->ip_dst.s_addr & ~vnetwork_mask.s_addr) ==
145 ~vnetwork_mask.s_addr)
146 goto bad;
147
148 for (ex_ptr = exec_list; ex_ptr; ex_ptr = ex_ptr->ex_next)
149 if (ex_ptr->ex_addr.s_addr == ip->ip_dst.s_addr)
150 break;
151
152 if (!ex_ptr)
153 goto bad;
154 }
155 }
156
157 /* Should drop packet if mbuf too long? hmmm... */
158 if (m->m_len > ip->ip_len)
159 m_adj(m, ip->ip_len - m->m_len);
160
161 /* check ip_ttl for a correct ICMP reply */
162 if(ip->ip_ttl==0 || ip->ip_ttl==1) {
163 icmp_error(m, ICMP_TIMXCEED,ICMP_TIMXCEED_INTRANS, 0,"ttl");
164 goto bad;
165 }
166
167 /*
168 * If offset or IP_MF are set, must reassemble.
169 * Otherwise, nothing need be done.
170 * (We could look in the reassembly queue to see
171 * if the packet was previously fragmented,
172 * but it's not worth the time; just let them time out.)
173 *
174 * XXX This should fail, don't fragment yet
175 */
176 if (ip->ip_off &~ IP_DF) {
177 register struct ipq *fp;
178 struct qlink *l;
179 /*
180 * Look for queue of fragments
181 * of this datagram.
182 */
183 for (l = ipq.ip_link.next; l != &ipq.ip_link; l = l->next) {
184 fp = container_of(l, struct ipq, ip_link);
185 if (ip->ip_id == fp->ipq_id &&
186 ip->ip_src.s_addr == fp->ipq_src.s_addr &&
187 ip->ip_dst.s_addr == fp->ipq_dst.s_addr &&
188 ip->ip_p == fp->ipq_p)
189 goto found;
190 }
191 fp = NULL;
192 found:
193
194 /*
195 * Adjust ip_len to not reflect header,
196 * set ip_mff if more fragments are expected,
197 * convert offset of this to bytes.
198 */
199 ip->ip_len -= hlen;
200 if (ip->ip_off & IP_MF)
201 ip->ip_tos |= 1;
202 else
203 ip->ip_tos &= ~1;
204
205 ip->ip_off <<= 3;
206
207 /*
208 * If datagram marked as having more fragments
209 * or if this is not the first fragment,
210 * attempt reassembly; if it succeeds, proceed.
211 */
212 if (ip->ip_tos & 1 || ip->ip_off) {
213 STAT(ipstat.ips_fragments++);
214 ip = ip_reass(ip, fp);
215 if (ip == NULL)
216 return;
217 STAT(ipstat.ips_reassembled++);
218 m = dtom(ip);
219 } else
220 if (fp)
221 ip_freef(fp);
222
223 } else
224 ip->ip_len -= hlen;
225
226 /*
227 * Switch out to protocol's input routine.
228 */
229 STAT(ipstat.ips_delivered++);
230 switch (ip->ip_p) {
231 case IPPROTO_TCP:
232 tcp_input(m, hlen, (struct socket *)NULL);
233 break;
234 case IPPROTO_UDP:
235 udp_input(m, hlen);
236 break;
237 case IPPROTO_ICMP:
238 icmp_input(m, hlen);
239 break;
240 default:
241 STAT(ipstat.ips_noproto++);
242 m_free(m);
243 }
244 return;
245 bad:
246 m_freem(m);
247 return;
248 }
249
250 #define iptofrag(P) ((struct ipasfrag *)(((char*)(P)) - sizeof(struct qlink)))
251 #define fragtoip(P) ((struct ip*)(((char*)(P)) + sizeof(struct qlink)))
252 /*
253 * Take incoming datagram fragment and try to
254 * reassemble it into whole datagram. If a chain for
255 * reassembly of this datagram already exists, then it
256 * is given as fp; otherwise have to make a chain.
257 */
258 static struct ip *
259 ip_reass(register struct ip *ip, register struct ipq *fp)
260 {
261 register struct mbuf *m = dtom(ip);
262 register struct ipasfrag *q;
263 int hlen = ip->ip_hl << 2;
264 int i, next;
265
266 DEBUG_CALL("ip_reass");
267 DEBUG_ARG("ip = %lx", (long)ip);
268 DEBUG_ARG("fp = %lx", (long)fp);
269 DEBUG_ARG("m = %lx", (long)m);
270
271 /*
272 * Presence of header sizes in mbufs
273 * would confuse code below.
274 * Fragment m_data is concatenated.
275 */
276 m->m_data += hlen;
277 m->m_len -= hlen;
278
279 /*
280 * If first fragment to arrive, create a reassembly queue.
281 */
282 if (fp == NULL) {
283 struct mbuf *t;
284 if ((t = m_get()) == NULL) goto dropfrag;
285 fp = mtod(t, struct ipq *);
286 insque(&fp->ip_link, &ipq.ip_link);
287 fp->ipq_ttl = IPFRAGTTL;
288 fp->ipq_p = ip->ip_p;
289 fp->ipq_id = ip->ip_id;
290 fp->frag_link.next = fp->frag_link.prev = &fp->frag_link;
291 fp->ipq_src = ip->ip_src;
292 fp->ipq_dst = ip->ip_dst;
293 q = (struct ipasfrag *)fp;
294 goto insert;
295 }
296
297 /*
298 * Find a segment which begins after this one does.
299 */
300 for (q = fp->frag_link.next; q != (struct ipasfrag *)&fp->frag_link;
301 q = q->ipf_next)
302 if (q->ipf_off > ip->ip_off)
303 break;
304
305 /*
306 * If there is a preceding segment, it may provide some of
307 * our data already. If so, drop the data from the incoming
308 * segment. If it provides all of our data, drop us.
309 */
310 if (q->ipf_prev != &fp->frag_link) {
311 struct ipasfrag *pq = q->ipf_prev;
312 i = pq->ipf_off + pq->ipf_len - ip->ip_off;
313 if (i > 0) {
314 if (i >= ip->ip_len)
315 goto dropfrag;
316 m_adj(dtom(ip), i);
317 ip->ip_off += i;
318 ip->ip_len -= i;
319 }
320 }
321
322 /*
323 * While we overlap succeeding segments trim them or,
324 * if they are completely covered, dequeue them.
325 */
326 while (q != (struct ipasfrag*)&fp->frag_link &&
327 ip->ip_off + ip->ip_len > q->ipf_off) {
328 i = (ip->ip_off + ip->ip_len) - q->ipf_off;
329 if (i < q->ipf_len) {
330 q->ipf_len -= i;
331 q->ipf_off += i;
332 m_adj(dtom(q), i);
333 break;
334 }
335 q = q->ipf_next;
336 m_freem(dtom(q->ipf_prev));
337 ip_deq(q->ipf_prev);
338 }
339
340 insert:
341 /*
342 * Stick new segment in its place;
343 * check for complete reassembly.
344 */
345 ip_enq(iptofrag(ip), q->ipf_prev);
346 next = 0;
347 for (q = fp->frag_link.next; q != (struct ipasfrag*)&fp->frag_link;
348 q = q->ipf_next) {
349 if (q->ipf_off != next)
350 return NULL;
351 next += q->ipf_len;
352 }
353 if (((struct ipasfrag *)(q->ipf_prev))->ipf_tos & 1)
354 return NULL;
355
356 /*
357 * Reassembly is complete; concatenate fragments.
358 */
359 q = fp->frag_link.next;
360 m = dtom(q);
361
362 q = (struct ipasfrag *) q->ipf_next;
363 while (q != (struct ipasfrag*)&fp->frag_link) {
364 struct mbuf *t = dtom(q);
365 q = (struct ipasfrag *) q->ipf_next;
366 m_cat(m, t);
367 }
368
369 /*
370 * Create header for new ip packet by
371 * modifying header of first packet;
372 * dequeue and discard fragment reassembly header.
373 * Make header visible.
374 */
375 q = fp->frag_link.next;
376
377 /*
378 * If the fragments concatenated to an mbuf that's
379 * bigger than the total size of the fragment, then and
380 * m_ext buffer was alloced. But fp->ipq_next points to
381 * the old buffer (in the mbuf), so we must point ip
382 * into the new buffer.
383 */
384 if (m->m_flags & M_EXT) {
385 int delta = (char *)q - m->m_dat;
386 q = (struct ipasfrag *)(m->m_ext + delta);
387 }
388
389 ip = fragtoip(q);
390 ip->ip_len = next;
391 ip->ip_tos &= ~1;
392 ip->ip_src = fp->ipq_src;
393 ip->ip_dst = fp->ipq_dst;
394 remque(&fp->ip_link);
395 (void) m_free(dtom(fp));
396 m->m_len += (ip->ip_hl << 2);
397 m->m_data -= (ip->ip_hl << 2);
398
399 return ip;
400
401 dropfrag:
402 STAT(ipstat.ips_fragdropped++);
403 m_freem(m);
404 return NULL;
405 }
406
407 /*
408 * Free a fragment reassembly header and all
409 * associated datagrams.
410 */
411 static void
412 ip_freef(struct ipq *fp)
413 {
414 register struct ipasfrag *q, *p;
415
416 for (q = fp->frag_link.next; q != (struct ipasfrag*)&fp->frag_link; q = p) {
417 p = q->ipf_next;
418 ip_deq(q);
419 m_freem(dtom(q));
420 }
421 remque(&fp->ip_link);
422 (void) m_free(dtom(fp));
423 }
424
425 /*
426 * Put an ip fragment on a reassembly chain.
427 * Like insque, but pointers in middle of structure.
428 */
429 static void
430 ip_enq(register struct ipasfrag *p, register struct ipasfrag *prev)
431 {
432 DEBUG_CALL("ip_enq");
433 DEBUG_ARG("prev = %lx", (long)prev);
434 p->ipf_prev = prev;
435 p->ipf_next = prev->ipf_next;
436 ((struct ipasfrag *)(prev->ipf_next))->ipf_prev = p;
437 prev->ipf_next = p;
438 }
439
440 /*
441 * To ip_enq as remque is to insque.
442 */
443 static void
444 ip_deq(register struct ipasfrag *p)
445 {
446 ((struct ipasfrag *)(p->ipf_prev))->ipf_next = p->ipf_next;
447 ((struct ipasfrag *)(p->ipf_next))->ipf_prev = p->ipf_prev;
448 }
449
450 /*
451 * IP timer processing;
452 * if a timer expires on a reassembly
453 * queue, discard it.
454 */
455 void
456 ip_slowtimo(void)
457 {
458 struct qlink *l;
459
460 DEBUG_CALL("ip_slowtimo");
461
462 l = ipq.ip_link.next;
463
464 if (l == NULL)
465 return;
466
467 while (l != &ipq.ip_link) {
468 struct ipq *fp = container_of(l, struct ipq, ip_link);
469 l = l->next;
470 if (--fp->ipq_ttl == 0) {
471 STAT(ipstat.ips_fragtimeout++);
472 ip_freef(fp);
473 }
474 }
475 }
476
477 /*
478 * Do option processing on a datagram,
479 * possibly discarding it if bad options are encountered,
480 * or forwarding it if source-routed.
481 * Returns 1 if packet has been forwarded/freed,
482 * 0 if the packet should be processed further.
483 */
484
485 #ifdef notdef
486
487 int
488 ip_dooptions(m)
489 struct mbuf *m;
490 {
491 register struct ip *ip = mtod(m, struct ip *);
492 register u_char *cp;
493 register struct ip_timestamp *ipt;
494 register struct in_ifaddr *ia;
495 int opt, optlen, cnt, off, code, type, forward = 0;
496 struct in_addr *sin, dst;
497 typedef u_int32_t n_time;
498 n_time ntime;
499
500 dst = ip->ip_dst;
501 cp = (u_char *)(ip + 1);
502 cnt = (ip->ip_hl << 2) - sizeof (struct ip);
503 for (; cnt > 0; cnt -= optlen, cp += optlen) {
504 opt = cp[IPOPT_OPTVAL];
505 if (opt == IPOPT_EOL)
506 break;
507 if (opt == IPOPT_NOP)
508 optlen = 1;
509 else {
510 optlen = cp[IPOPT_OLEN];
511 if (optlen <= 0 || optlen > cnt) {
512 code = &cp[IPOPT_OLEN] - (u_char *)ip;
513 goto bad;
514 }
515 }
516 switch (opt) {
517
518 default:
519 break;
520
521 /*
522 * Source routing with record.
523 * Find interface with current destination address.
524 * If none on this machine then drop if strictly routed,
525 * or do nothing if loosely routed.
526 * Record interface address and bring up next address
527 * component. If strictly routed make sure next
528 * address is on directly accessible net.
529 */
530 case IPOPT_LSRR:
531 case IPOPT_SSRR:
532 if ((off = cp[IPOPT_OFFSET]) < IPOPT_MINOFF) {
533 code = &cp[IPOPT_OFFSET] - (u_char *)ip;
534 goto bad;
535 }
536 ipaddr.sin_addr = ip->ip_dst;
537 ia = (struct in_ifaddr *)
538 ifa_ifwithaddr((struct sockaddr *)&ipaddr);
539 if (ia == 0) {
540 if (opt == IPOPT_SSRR) {
541 type = ICMP_UNREACH;
542 code = ICMP_UNREACH_SRCFAIL;
543 goto bad;
544 }
545 /*
546 * Loose routing, and not at next destination
547 * yet; nothing to do except forward.
548 */
549 break;
550 }
551 off--; / * 0 origin * /
552 if (off > optlen - sizeof(struct in_addr)) {
553 /*
554 * End of source route. Should be for us.
555 */
556 save_rte(cp, ip->ip_src);
557 break;
558 }
559 /*
560 * locate outgoing interface
561 */
562 bcopy((caddr_t)(cp + off), (caddr_t)&ipaddr.sin_addr,
563 sizeof(ipaddr.sin_addr));
564 if (opt == IPOPT_SSRR) {
565 #define INA struct in_ifaddr *
566 #define SA struct sockaddr *
567 if ((ia = (INA)ifa_ifwithdstaddr((SA)&ipaddr)) == 0)
568 ia = (INA)ifa_ifwithnet((SA)&ipaddr);
569 } else
570 ia = ip_rtaddr(ipaddr.sin_addr);
571 if (ia == 0) {
572 type = ICMP_UNREACH;
573 code = ICMP_UNREACH_SRCFAIL;
574 goto bad;
575 }
576 ip->ip_dst = ipaddr.sin_addr;
577 bcopy((caddr_t)&(IA_SIN(ia)->sin_addr),
578 (caddr_t)(cp + off), sizeof(struct in_addr));
579 cp[IPOPT_OFFSET] += sizeof(struct in_addr);
580 /*
581 * Let ip_intr's mcast routing check handle mcast pkts
582 */
583 forward = !IN_MULTICAST(ntohl(ip->ip_dst.s_addr));
584 break;
585
586 case IPOPT_RR:
587 if ((off = cp[IPOPT_OFFSET]) < IPOPT_MINOFF) {
588 code = &cp[IPOPT_OFFSET] - (u_char *)ip;
589 goto bad;
590 }
591 /*
592 * If no space remains, ignore.
593 */
594 off--; * 0 origin *
595 if (off > optlen - sizeof(struct in_addr))
596 break;
597 bcopy((caddr_t)(&ip->ip_dst), (caddr_t)&ipaddr.sin_addr,
598 sizeof(ipaddr.sin_addr));
599 /*
600 * locate outgoing interface; if we're the destination,
601 * use the incoming interface (should be same).
602 */
603 if ((ia = (INA)ifa_ifwithaddr((SA)&ipaddr)) == 0 &&
604 (ia = ip_rtaddr(ipaddr.sin_addr)) == 0) {
605 type = ICMP_UNREACH;
606 code = ICMP_UNREACH_HOST;
607 goto bad;
608 }
609 bcopy((caddr_t)&(IA_SIN(ia)->sin_addr),
610 (caddr_t)(cp + off), sizeof(struct in_addr));
611 cp[IPOPT_OFFSET] += sizeof(struct in_addr);
612 break;
613
614 case IPOPT_TS:
615 code = cp - (u_char *)ip;
616 ipt = (struct ip_timestamp *)cp;
617 if (ipt->ipt_len < 5)
618 goto bad;
619 if (ipt->ipt_ptr > ipt->ipt_len - sizeof (int32_t)) {
620 if (++ipt->ipt_oflw == 0)
621 goto bad;
622 break;
623 }
624 sin = (struct in_addr *)(cp + ipt->ipt_ptr - 1);
625 switch (ipt->ipt_flg) {
626
627 case IPOPT_TS_TSONLY:
628 break;
629
630 case IPOPT_TS_TSANDADDR:
631 if (ipt->ipt_ptr + sizeof(n_time) +
632 sizeof(struct in_addr) > ipt->ipt_len)
633 goto bad;
634 ipaddr.sin_addr = dst;
635 ia = (INA)ifaof_ i f p foraddr((SA)&ipaddr,
636 m->m_pkthdr.rcvif);
637 if (ia == 0)
638 continue;
639 bcopy((caddr_t)&IA_SIN(ia)->sin_addr,
640 (caddr_t)sin, sizeof(struct in_addr));
641 ipt->ipt_ptr += sizeof(struct in_addr);
642 break;
643
644 case IPOPT_TS_PRESPEC:
645 if (ipt->ipt_ptr + sizeof(n_time) +
646 sizeof(struct in_addr) > ipt->ipt_len)
647 goto bad;
648 bcopy((caddr_t)sin, (caddr_t)&ipaddr.sin_addr,
649 sizeof(struct in_addr));
650 if (ifa_ifwithaddr((SA)&ipaddr) == 0)
651 continue;
652 ipt->ipt_ptr += sizeof(struct in_addr);
653 break;
654
655 default:
656 goto bad;
657 }
658 ntime = iptime();
659 bcopy((caddr_t)&ntime, (caddr_t)cp + ipt->ipt_ptr - 1,
660 sizeof(n_time));
661 ipt->ipt_ptr += sizeof(n_time);
662 }
663 }
664 if (forward) {
665 ip_forward(m, 1);
666 return (1);
667 }
668 }
669 }
670 return (0);
671 bad:
672 icmp_error(m, type, code, 0, 0);
673
674 STAT(ipstat.ips_badoptions++);
675 return (1);
676 }
677
678 #endif /* notdef */
679
680 /*
681 * Strip out IP options, at higher
682 * level protocol in the kernel.
683 * Second argument is buffer to which options
684 * will be moved, and return value is their length.
685 * (XXX) should be deleted; last arg currently ignored.
686 */
687 void
688 ip_stripoptions(register struct mbuf *m, struct mbuf *mopt)
689 {
690 register int i;
691 struct ip *ip = mtod(m, struct ip *);
692 register caddr_t opts;
693 int olen;
694
695 olen = (ip->ip_hl<<2) - sizeof (struct ip);
696 opts = (caddr_t)(ip + 1);
697 i = m->m_len - (sizeof (struct ip) + olen);
698 memcpy(opts, opts + olen, (unsigned)i);
699 m->m_len -= olen;
700
701 ip->ip_hl = sizeof(struct ip) >> 2;
702 }