Some problems about XLS files in encryption/decryption.

Dear All,

I am developing a FS mini-filter driver for file encryption/decryption.
In the XXXX_PreCreateCallback routine(IRP_MJ_CREATE), I am checking the
creating file name, and if the file is in my encryption list and this
routine will return the value of FLT_PREOP_SUCCESS_WITH_CALLBACK, and then
in the XXXX_PostCreateCallback routine(IRP_MJ_CREATE), I will allocate a
StreamHandle Context and set some information in the context for the
following Read/Write operation of this stream handle.
In the Read/Write operation callback routine(IRP_MJ_READ/IRP_MJ_WRITE), at
first I will try to get the stream handle context, and if I got it and I
will decrypting/encrypting the data stream for Read/Write operation.
The encrypted TXT,DOC,ZIP,BMP files work fine, but encrypted XLS,PPT,MDB
files will be corrupted after the PC reboot.

Thanks,
Ben Wang

> The encrypted TXT,DOC,ZIP,BMP files work fine, but encrypted XLS,PPT,MDB

files will be corrupted after the PC reboot.

It seems like you are combining encryption on both cached
and non-cached I/O requests (Paging I/O).

Please, don’t take the following advice wrong or as an offence,
but on one of the previoud posts, David Craig and I said you that
you should really read some docs and also that an encryption
filter is one of the most difficult tasks to do. Believe the others,
they are not kidding. This question further shows that you
don’t have sufficient knowledge about file systems.
Lack of knowledge in this area will result is such problems,
and the problems will go worse.

Later, you will have to solve problems which may take days even for
experienced developers. No member of this forum will know
the answer, what then ?

If you are working under management’s time pressure,
you have to convince them that what you are trying
to achieve is really not an easy task that can be done
in month or two.

L.

No, when I register the Read/Write callback, I set the flag
FLTFL_OPERATION_REGISTRATION_SKIP_CACHED_IO.

“Ladislav Zezula” ???:xxxxx@ntfsd…
>> The encrypted TXT,DOC,ZIP,BMP files work fine, but encrypted XLS,PPT,MDB
>> files will be corrupted after the PC reboot.
>
> It seems like you are combining encryption on both cached
> and non-cached I/O requests (Paging I/O).
>
> Please, don’t take the following advice wrong or as an offence,
> but on one of the previoud posts, David Craig and I said you that
> you should really read some docs and also that an encryption
> filter is one of the most difficult tasks to do. Believe the others,
> they are not kidding. This question further shows that you
> don’t have sufficient knowledge about file systems.
> Lack of knowledge in this area will result is such problems,
> and the problems will go worse.
> Later, you will have to solve problems which may take days even for
> experienced developers. No member of this forum will know
> the answer, what then ?
>
> If you are working under management’s time pressure,
> you have to convince them that what you are trying
> to achieve is really not an easy task that can be done
> in month or two.
>
> L.
>
>