Hi.
On Fri, Aug 08, 2008 at 11:31:58AM -0700, Shasi Pulijala ([EMAIL PROTECTED])
wrote:
> struct crypt_op {
> - u_int32_t ses;
> - u_int16_t op; /* i.e. COP_ENCRYPT */
> #define COP_NONE 0
> #define COP_ENCRYPT 1
> #define COP_DECRYPT 2
> - u_int16_t flags;
> -#define COP_F_BATCH 0x0008 /* Batch op if possible */
> - u_int len;
> - caddr_t src, dst; /* become iov[] inside kernel */
> - caddr_t mac; /* must be big enough for chosen MAC */
> - caddr_t iv;
> + __u16 op; /* i.e. COP_ENCRYPT */
> + __u16 flags;
> + __u16 iv_size;
> + __u16 assoc_size;
> + __u32 src_size;
> + caddr_t src_data;
> + caddr_t dst_data;
> + __u8 data[0]; /* must be big enough for chosen MAC */
> };
If above caddr_t is what I thought (i.e. a pointer or long type),
there is no way it can be correct. It is _NOT_ allowed to put
variable sized members into structures shared between kernel
and userspace.
--
Evgeniy Polyakov
--
To unsubscribe from this list: send the line "unsubscribe linux-crypto" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html