Simulate format command ???

Dear All,

I am trying to develop a utility which simulates ‘format DOS command’.
eg. format /fs:NTFS f:

From my search I have come to know that format command passes request
from user level to IOCTL_DISK_VERIFY at kernel level.So I tried to format
a raw disk using IOCTL_DISK_VERIFY in my program (using all required
parameters such as DISK_VERIFY structure,).

But it didnot worked at all.
Are there any other IOCTLs also where format command sends its request to
?
Or Can anybody please suggest any alternative method to proceed for it.

Thanks in advance.

Rohit

I can send you sources for the utility that we use to format our FS -
without any FS specific code of course (so you can’t compile it, but you can
see all requires steps!)
Let me know via private e-mail if you need this.

Rohit wrote:

Dear All,

I am trying to develop a utility which simulates ‘format DOS command’.
eg. format /fs:NTFS f:

>From my search I have come to know that format command passes request
from user level to IOCTL_DISK_VERIFY at kernel level.So I tried to format
a raw disk using IOCTL_DISK_VERIFY in my program (using all required
parameters such as DISK_VERIFY structure,).

But it didnot worked at all.
Are there any other IOCTLs also where format command sends its request to
?
Or Can anybody please suggest any alternative method to proceed for it.

Thanks in advance.

Rohit


You are currently subscribed to ntfsd as: xxxxx@alfasp.com
To unsubscribe send a blank email to xxxxx@lists.osr.com


Kind regards, Dejan M. MVP for DDK
http://www.alfasp.com E-mail: xxxxx@alfasp.com
Alfa Transparent File Encryptor - Transparent file encryption services.
Alfa File Protector - File protection and hiding library for Win32
developers.
Alfa File Monitor - File monitoring library for Win32 developers.

Can’t you just open a file handle directly to the disk drive and write the
bytes out to construct your FS in user mode?

----- Original Message -----
From: “Dejan Maksimovic”
To: “File Systems Developers”
Sent: Tuesday, May 27, 2003 8:06 AM
Subject: [ntfsd] Re: Simulate format command ???

>
> I can send you sources for the utility that we use to format our FS -
> without any FS specific code of course (so you can’t compile it, but you
can
> see all requires steps!)
> Let me know via private e-mail if you need this.
>
> Rohit wrote:
>
> > Dear All,
> >
> > I am trying to develop a utility which simulates ‘format DOS command’.
> > eg. format /fs:NTFS f:
> >
> > >From my search I have come to know that format command passes request
> > from user level to IOCTL_DISK_VERIFY at kernel level.So I tried to
format
> > a raw disk using IOCTL_DISK_VERIFY in my program (using all required
> > parameters such as DISK_VERIFY structure,).
> >
> > But it didnot worked at all.
> > Are there any other IOCTLs also where format command sends its request
to
> > ?
> > Or Can anybody please suggest any alternative method to proceed for it.
> >
> > Thanks in advance.
> >
> > Rohit
> >
> > —
> > You are currently subscribed to ntfsd as: xxxxx@alfasp.com
> > To unsubscribe send a blank email to xxxxx@lists.osr.com
>
> –
> Kind regards, Dejan M. MVP for DDK
> http://www.alfasp.com E-mail: xxxxx@alfasp.com
> Alfa Transparent File Encryptor - Transparent file encryption services.
> Alfa File Protector - File protection and hiding library for Win32
> developers.
> Alfa File Monitor - File monitoring library for Win32 developers.
>
>
>
>
> —
> You are currently subscribed to ntfsd as: xxxxx@sftechserv.com
> To unsubscribe send a blank email to xxxxx@lists.osr.com
>

That’s what I did:-)

William Chow wrote:

Can’t you just open a file handle directly to the disk drive and write the
bytes out to construct your FS in user mode?

----- Original Message -----
From: “Dejan Maksimovic”
> To: “File Systems Developers”
> Sent: Tuesday, May 27, 2003 8:06 AM
> Subject: [ntfsd] Re: Simulate format command ???
>
> >
> > I can send you sources for the utility that we use to format our FS -
> > without any FS specific code of course (so you can’t compile it, but you
> can
> > see all requires steps!)
> > Let me know via private e-mail if you need this.
> >
> > Rohit wrote:
> >
> > > Dear All,
> > >
> > > I am trying to develop a utility which simulates ‘format DOS command’.
> > > eg. format /fs:NTFS f:
> > >
> > > >From my search I have come to know that format command passes request
> > > from user level to IOCTL_DISK_VERIFY at kernel level.So I tried to
> format
> > > a raw disk using IOCTL_DISK_VERIFY in my program (using all required
> > > parameters such as DISK_VERIFY structure,).
> > >
> > > But it didnot worked at all.
> > > Are there any other IOCTLs also where format command sends its request
> to
> > > ?
> > > Or Can anybody please suggest any alternative method to proceed for it.
> > >
> > > Thanks in advance.
> > >
> > > Rohit
> > >
> > > —
> > > You are currently subscribed to ntfsd as: xxxxx@alfasp.com
> > > To unsubscribe send a blank email to xxxxx@lists.osr.com
> >
> > –
> > Kind regards, Dejan M. MVP for DDK
> > http://www.alfasp.com E-mail: xxxxx@alfasp.com
> > Alfa Transparent File Encryptor - Transparent file encryption services.
> > Alfa File Protector - File protection and hiding library for Win32
> > developers.
> > Alfa File Monitor - File monitoring library for Win32 developers.
> >
> >
> >
> >
> > —
> > You are currently subscribed to ntfsd as: xxxxx@sftechserv.com
> > To unsubscribe send a blank email to xxxxx@lists.osr.com
> >
>
> —
> You are currently subscribed to ntfsd as: xxxxx@alfasp.com
> To unsubscribe send a blank email to xxxxx@lists.osr.com


Kind regards, Dejan M. MVP for DDK
http://www.alfasp.com E-mail: xxxxx@alfasp.com
Alfa Transparent File Encryptor - Transparent file encryption services.
Alfa File Protector - File protection and hiding library for Win32 developers.
Alfa File Monitor - File monitoring library for Win32 developers.

Actually, I’m curious. I’m aware that FAT and NTFS have a UFAT/UNTFS.DLL
used by format and chkdsk as well as Windows Explorer to format drives. I’ve
never bothered to register my own format utilties into Windows Explorer. Is
it actually possible to integrate one’s proprietary format so that Windows
will automatically add it as an option when you format, so say I replicate
the API found in the DLLs? Is there a registry hack so that it lists another
possible entry for formatting?

----- Original Message -----
From: “Dejan Maksimovic”
To: “File Systems Developers”
Sent: Tuesday, May 27, 2003 11:07 AM
Subject: [ntfsd] Re: Simulate format command ???

>
> That’s what I did:-)
>
> William Chow wrote:
>
> > Can’t you just open a file handle directly to the disk drive and write
the
> > bytes out to construct your FS in user mode?
> >
> > ----- Original Message -----
> > From: “Dejan Maksimovic”
> > To: “File Systems Developers”
> > Sent: Tuesday, May 27, 2003 8:06 AM
> > Subject: [ntfsd] Re: Simulate format command ???
> >
> > >
> > > I can send you sources for the utility that we use to format our
FS -
> > > without any FS specific code of course (so you can’t compile it, but
you
> > can
> > > see all requires steps!)
> > > Let me know via private e-mail if you need this.
> > >
> > > Rohit wrote:
> > >
> > > > Dear All,
> > > >
> > > > I am trying to develop a utility which simulates ‘format DOS
command’.
> > > > eg. format /fs:NTFS f:
> > > >
> > > > >From my search I have come to know that format command passes
request
> > > > from user level to IOCTL_DISK_VERIFY at kernel level.So I tried to
> > format
> > > > a raw disk using IOCTL_DISK_VERIFY in my program (using all required
> > > > parameters such as DISK_VERIFY structure,).
> > > >
> > > > But it didnot worked at all.
> > > > Are there any other IOCTLs also where format command sends its
request
> > to
> > > > ?
> > > > Or Can anybody please suggest any alternative method to proceed for
it.
> > > >
> > > > Thanks in advance.
> > > >
> > > > Rohit
> > > >
> > > > —
> > > > You are currently subscribed to ntfsd as: xxxxx@alfasp.com
> > > > To unsubscribe send a blank email to xxxxx@lists.osr.com
> > >
> > > –
> > > Kind regards, Dejan M. MVP for DDK
> > > http://www.alfasp.com E-mail: xxxxx@alfasp.com
> > > Alfa Transparent File Encryptor - Transparent file encryption
services.
> > > Alfa File Protector - File protection and hiding library for Win32
> > > developers.
> > > Alfa File Monitor - File monitoring library for Win32 developers.
> > >
> > >
> > >
> > >
> > > —
> > > You are currently subscribed to ntfsd as: xxxxx@sftechserv.com
> > > To unsubscribe send a blank email to xxxxx@lists.osr.com
> > >
> >
> > —
> > You are currently subscribed to ntfsd as: xxxxx@alfasp.com
> > To unsubscribe send a blank email to xxxxx@lists.osr.com
>
> –
> Kind regards, Dejan M. MVP for DDK
> http://www.alfasp.com E-mail: xxxxx@alfasp.com
> Alfa Transparent File Encryptor - Transparent file encryption services.
> Alfa File Protector - File protection and hiding library for Win32
developers.
> Alfa File Monitor - File monitoring library for Win32 developers.
>
>
>
>
> —
> You are currently subscribed to ntfsd as: xxxxx@sftechserv.com
> To unsubscribe send a blank email to xxxxx@lists.osr.com
>

To mimic FORMAT, you must be able to write the empty filesystem volume
sector-wise by hand. The FSD cannot do this.

Max

----- Original Message -----
From: “Rohit”
To: “File Systems Developers”
Sent: Tuesday, May 27, 2003 5:44 PM
Subject: [ntfsd] Simulate format command ???

> Dear All,
>
> I am trying to develop a utility which simulates ‘format DOS
command’.
> eg. format /fs:NTFS f:
>
> From my search I have come to know that format command passes
request
> from user level to IOCTL_DISK_VERIFY at kernel level.So I tried to
format
> a raw disk using IOCTL_DISK_VERIFY in my program (using all required
> parameters such as DISK_VERIFY structure,).
>
> But it didnot worked at all.
> Are there any other IOCTLs also where format command sends its
request to
> ?
> Or Can anybody please suggest any alternative method to proceed for
it.
>
> Thanks in advance.
>
> Rohit
>
> —
> You are currently subscribed to ntfsd as: xxxxx@storagecraft.com
> To unsubscribe send a blank email to xxxxx@lists.osr.com

Dear Max,
Yes, I have coded for developing the empty filesystem volume.
Thank to all for the useful suggestions.
Rohit

If anyone asked me for the format utility and didn’t receive it yet,
e-mail me again (your virus scanner might’ve rejected the e-mail as I
attached a C file, which I didn’t zip)

Rohit wrote:

Dear Max,
Yes, I have coded for developing the empty filesystem volume.
Thank to all for the useful suggestions.
Rohit


You are currently subscribed to ntfsd as: xxxxx@alfasp.com
To unsubscribe send a blank email to xxxxx@lists.osr.com


Kind regards, Dejan M. MVP for DDK
http://www.alfasp.com E-mail: xxxxx@alfasp.com
Alfa Transparent File Encryptor - Transparent file encryption services.
Alfa File Protector - File protection and hiding library for Win32
developers.
Alfa File Monitor - File monitoring library for Win32 developers.

Dear Dejan,
I have recieved your code, will go through it today and will revert you
back. Thanks a lot for you co operation
Rohit