From owner-freebsd-net Mon Dec 9 6:44: 2 2002 Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AAACD37B401 for ; Mon, 9 Dec 2002 06:44:01 -0800 (PST) Received: from fledge.watson.org (fledge.watson.org [204.156.12.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id F0CB143EC5 for ; Mon, 9 Dec 2002 06:44:00 -0800 (PST) (envelope-from robert@fledge.watson.org) Received: from fledge.watson.org (fledge.pr.watson.org [192.0.2.3]) by fledge.watson.org (8.12.6/8.12.5) with SMTP id gB9EhsBF070622; Mon, 9 Dec 2002 09:43:54 -0500 (EST) (envelope-from robert@fledge.watson.org) Date: Mon, 9 Dec 2002 09:43:54 -0500 (EST) From: Robert Watson X-Sender: robert@fledge.watson.org To: soheil soheil Cc: freebsd-net@freebsd.org Subject: Re: Spoofing Another Host Packet From User Land In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-net@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org On Mon, 9 Dec 2002, soheil soheil wrote: > I want to know if i can use SOCK_RAW to create and send another Host ( > with another IP) Packet from my box. Sayin' in another way , i want to > know if the kernel fill the ip:ip_src field of the packet throw out by > SOCK_RAW ? if i can not do this by raw socket how can i do that ? The ip(4) man page has a description of IP raw sockets in detail; the socket option you're interested in is IP_HDRINCL. You may want to dig up one of the network programming books by Stevens to find out more about low level network programming. Robert N M Watson FreeBSD Core Team, TrustedBSD Projects robert@fledge.watson.org Network Associates Laboratories To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message