Rev 3545 | Rev 3600 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 3545 | Rev 3556 | ||
---|---|---|---|
Line 81... | Line 81... | ||
81 | ; |
81 | ; |
82 | ;----------------------------------------------------------------- |
82 | ;----------------------------------------------------------------- |
83 | align 4 |
83 | align 4 |
84 | IPv6_input: |
84 | IPv6_input: |
Line 85... | Line 85... | ||
85 | 85 | ||
86 | DEBUGF 2,"IPv6_input from: %x%x:%x%x:%x%x:%x%x:%x%x:%x%x:%x%x:%x%x\n",\ |
86 | DEBUGF DEBUG_NETWORK_VERBOSE, "IPv6_input from: %x%x:%x%x:%x%x:%x%x:%x%x:%x%x:%x%x:%x%x\n",\ |
87 | [edx + IPv6_header.SourceAddress + 0]:2,[edx + IPv6_header.SourceAddress + 1]:2,\ |
87 | [edx + IPv6_header.SourceAddress + 0]:2,[edx + IPv6_header.SourceAddress + 1]:2,\ |
88 | [edx + IPv6_header.SourceAddress + 2]:2,[edx + IPv6_header.SourceAddress + 3]:2,\ |
88 | [edx + IPv6_header.SourceAddress + 2]:2,[edx + IPv6_header.SourceAddress + 3]:2,\ |
89 | [edx + IPv6_header.SourceAddress + 4]:2,[edx + IPv6_header.SourceAddress + 5]:2,\ |
89 | [edx + IPv6_header.SourceAddress + 4]:2,[edx + IPv6_header.SourceAddress + 5]:2,\ |
90 | [edx + IPv6_header.SourceAddress + 6]:2,[edx + IPv6_header.SourceAddress + 7]:2,\ |
90 | [edx + IPv6_header.SourceAddress + 6]:2,[edx + IPv6_header.SourceAddress + 7]:2,\ |
91 | [edx + IPv6_header.SourceAddress + 8]:2,[edx + IPv6_header.SourceAddress + 9]:2,\ |
91 | [edx + IPv6_header.SourceAddress + 8]:2,[edx + IPv6_header.SourceAddress + 9]:2,\ |
92 | [edx + IPv6_header.SourceAddress + 10]:2,[edx + IPv6_header.SourceAddress + 11]:2,\ |
92 | [edx + IPv6_header.SourceAddress + 10]:2,[edx + IPv6_header.SourceAddress + 11]:2,\ |
93 | [edx + IPv6_header.SourceAddress + 12]:2,[edx + IPv6_header.SourceAddress + 13]:2,\ |
93 | [edx + IPv6_header.SourceAddress + 12]:2,[edx + IPv6_header.SourceAddress + 13]:2,\ |
Line 94... | Line 94... | ||
94 | [edx + IPv6_header.SourceAddress + 14]:2,[edx + IPv6_header.SourceAddress + 15]:2 |
94 | [edx + IPv6_header.SourceAddress + 14]:2,[edx + IPv6_header.SourceAddress + 15]:2 |
95 | 95 | ||
96 | DEBUGF 1,"IPv6_input to: %x%x:%x%x:%x%x:%x%x:%x%x:%x%x:%x%x:%x%x\n",\ |
96 | DEBUGF DEBUG_NETWORK_VERBOSE, "IPv6_input to: %x%x:%x%x:%x%x:%x%x:%x%x:%x%x:%x%x:%x%x\n",\ |
97 | [edx + IPv6_header.DestinationAddress + 0]:2,[edx + IPv6_header.DestinationAddress + 1]:2,\ |
97 | [edx + IPv6_header.DestinationAddress + 0]:2,[edx + IPv6_header.DestinationAddress + 1]:2,\ |
98 | [edx + IPv6_header.DestinationAddress + 2]:2,[edx + IPv6_header.DestinationAddress + 3]:2,\ |
98 | [edx + IPv6_header.DestinationAddress + 2]:2,[edx + IPv6_header.DestinationAddress + 3]:2,\ |
99 | [edx + IPv6_header.DestinationAddress + 4]:2,[edx + IPv6_header.DestinationAddress + 5]:2,\ |
99 | [edx + IPv6_header.DestinationAddress + 4]:2,[edx + IPv6_header.DestinationAddress + 5]:2,\ |
Line 141... | Line 141... | ||
141 | ; je UDP_input |
141 | ; je UDP_input |
Line 142... | Line 142... | ||
142 | 142 | ||
143 | ; cmp al, 58 |
143 | ; cmp al, 58 |
Line 144... | Line 144... | ||
144 | ; je ICMP6_input |
144 | ; je ICMP6_input |
Line 145... | Line 145... | ||
145 | 145 | ||
146 | DEBUGF 2,"IPv6_input - unknown protocol: %u\n", al |
146 | DEBUGF DEBUG_NETWORK_VERBOSE, "IPv6_input - unknown protocol: %u\n", al |
147 | 147 | ||
148 | .dump: |
148 | .dump: |
Line 149... | Line 149... | ||
149 | DEBUGF 1,"IPv6_input - dumping\n" |
149 | DEBUGF DEBUG_NETWORK_VERBOSE, "IPv6_input - dumping\n" |
Line 164... | Line 164... | ||
164 | 164 | ||
165 | ;------------------------- |
165 | ;------------------------- |
Line 166... | Line 166... | ||
166 | ; Hop-by-Hop |
166 | ; Hop-by-Hop |
167 | 167 | ||
168 | .hop_by_hop: |
168 | .hop_by_hop: |
169 | DEBUGF 1,"IPv6_input - hop by hop\n" |
169 | DEBUGF DEBUG_NETWORK_VERBOSE, "IPv6_input - hop by hop\n" |
170 | pushw [esi] ; 8 bit identifier for option type |
170 | pushw [esi] ; 8 bit identifier for option type |
171 | movzx eax, byte[esi + 1] ; Hdr Ext Len |
171 | movzx eax, byte[esi + 1] ; Hdr Ext Len |
172 | inc eax ; first 8 octets not counted |
172 | inc eax ; first 8 octets not counted |
Line 193... | Line 193... | ||
193 | test al, 0xc0 ; discard packet |
193 | test al, 0xc0 ; discard packet |
194 | jnz .dump_options |
194 | jnz .dump_options |
Line 195... | Line 195... | ||
195 | 195 | ||
196 | .pad_n: |
196 | .pad_n: |
197 | movzx eax, byte[esi + 1] |
197 | movzx eax, byte[esi + 1] |
198 | DEBUGF 1,"IPv6_input - pad %u\n", eax |
198 | DEBUGF DEBUG_NETWORK_VERBOSE, "IPv6_input - pad %u\n", eax |
199 | inc esi |
199 | inc esi |
200 | inc esi |
200 | inc esi |
201 | add esi, eax |
201 | add esi, eax |
202 | sub ecx, eax |
202 | sub ecx, eax |
Line 203... | Line 203... | ||
203 | jmp .hop_by_hop |
203 | jmp .hop_by_hop |
204 | 204 | ||
205 | .pad_1: |
205 | .pad_1: |
206 | DEBUGF 1,"IPv6_input - pad 1\n" |
206 | DEBUGF DEBUG_NETWORK_VERBOSE, "IPv6_input - pad 1\n" |
207 | inc esi |
207 | inc esi |
Line 208... | Line 208... | ||
208 | dec ecx |
208 | dec ecx |
209 | jmp .hop_by_hop |
209 | jmp .hop_by_hop |
210 | 210 | ||
Line 211... | Line 211... | ||
211 | 211 | ||
212 | 212 | ||
213 | .dest_opts: |
213 | .dest_opts: |
214 | DEBUGF 1,"IPv6_input - dest opts\n" |
214 | DEBUGF DEBUG_NETWORK_VERBOSE, "IPv6_input - dest opts\n" |
215 | jmp .nextheader |
215 | jmp .nextheader |
216 | 216 | ||
217 | .routing: |
217 | .routing: |
Line 236... | Line 236... | ||
236 | mov al, [esi] ; routing type |
236 | mov al, [esi] ; routing type |
Line 237... | Line 237... | ||
237 | 237 | ||
Line 238... | Line 238... | ||
238 | jmp .nextheader |
238 | jmp .nextheader |
239 | 239 | ||
Line 240... | Line 240... | ||
240 | .fragment: |
240 | .fragment: |