PFIL: how to get tcp/ip fields from mbuf

2010-02-01 Thread Lukasz Jaroszewski
Hello, I am wondering about most elegant and proper way to get IP header fields from mbuf, using PFILs. I have read Murat Balaban paper on PFIL_HOOKS where I found some example function. Question is how can I access IP header field in such manner. static int hisar_chkinput(void *arg, struct mbuf *

Re: write(2) to /dev/ad4 = EINVAL

2009-01-26 Thread Lukasz Jaroszewski
2009/1/26 Christoph Mallon : > Lukasz Jaroszewski schrieb: >> >> 2009/1/26 Hans Petter Selasky : >>> >>> On Monday 26 January 2009, Lukasz Jaroszewski wrote: >>>> >>>> Hi, >>>> after opening /dev/ad4 with success for O_RDWR, I a

Re: write(2) to /dev/ad4 = EINVAL

2009-01-26 Thread Lukasz Jaroszewski
2009/1/26 Hans Petter Selasky : > On Monday 26 January 2009, Lukasz Jaroszewski wrote: >> Hi, >> after opening /dev/ad4 with success for O_RDWR, I am getting [EINVAL] >> from write(2), which according to man 2 write, means >> `` [EINVAL] The pointer associ

write(2) to /dev/ad4 = EINVAL

2009-01-26 Thread Lukasz Jaroszewski
Hi, after opening /dev/ad4 with success for O_RDWR, I am getting [EINVAL] from write(2), which according to man 2 write, means `` [EINVAL] The pointer associated with d was negative.'', as you can see below it is not true, I have tried different block sizes, with same result. How ca

Sockstress

2008-10-09 Thread Lukasz Jaroszewski
Hi, I am wondering about sockstres informations recently published. I cant really figure what new they could found. Do we have anything to worry about? ;-) http://searchsecurity.techtarget.com/news/article/0,289142,sid14_gci1332898,00.html ``(...)Sockstress computes and stores so-called client-si

Accessing char device from inside the kernel

2008-06-19 Thread Lukasz Jaroszewski
Hi, as described in topic. How one should access cdev for writing from kernel-level. What is the proper way to do that ? I will be thankful for any tips and few lines of example code would be just great. Best regards LVJ ___ freebsd-hackers@freebsd.org m

KLM - Fatal trap 12 on kldunload mod - sc replace

2008-06-16 Thread Lukasz Jaroszewski
Hi, I am trying to master kernel, first thought was to do simple replace of system call(read), tho i have some issues which I cant figure. My read_hack is supposed to log keystrokes, and it does.. tho only login and password typed from console but without 1st char(typed root appears as oot.), next

utmp.h: UT_HOSTSIZE

2008-05-06 Thread Lukasz Jaroszewski
Hi, just by curiosity, why #define UT_HOSTSIZE is 16, not 256, like in OtherBSDs and some unix-like-like OSes? :) Regards LVJ ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send an

RE: indent(1) support for gcc(1) 0b prefix

2008-04-28 Thread Lukasz Jaroszewski
>On Apr 26, 2008, at 5:01 PM, Max Laier wrote: >>* On Saturday 26 April 2008 23:35:57 Romain Tartière wrote: *>>>* Hello FreeBSD hackers! *>>>* *>>>* I'm using avr-gcc from the ports and relying on the 0b prefix *>>>* notation *>>>* for binary constants, that is: *>>>* *>>>* foo = 0b00101010; *>