2002-01-09 16:19:56

by Michael Zhu

[permalink] [raw]
Subject: About Loop Device

Hello,everyone,does anyone be familiar with the loop
device? I just read some source code of loop.c file. I
have some questions about this loop device. I am a new
one to this loop device. Thanks in advance.

I want to implement my own loop device which is used
to encrypt the whole disk,say /dev/fd0, even including
the boot sector on the floppy disk. How can I make a
connection between my own loop device with the floppy
disk? I mean how I can connect the loop device with
the floppy disk to hook the READ/WRITE operations to
the floppy disk.

Michael

______________________________________________________________________
Web-hosting solutions for home and business! http://website.yahoo.ca


2002-01-09 16:26:46

by Richard B. Johnson

[permalink] [raw]
Subject: Re: About Loop Device

On Wed, 9 Jan 2002, Michael Zhu wrote:
[SNIPPED...]

> connection between my own loop device with the floppy
> disk? I mean how I can connect the loop device with
> the floppy disk to hook the READ/WRITE operations to
> the floppy disk.
>
> Michael
>

mount -o loop /dev/fd0 /mnt

Cheers,
Dick Johnson

Penguin : Linux version 2.4.1 on an i686 machine (797.90 BogoMips).

I was going to compile a list of innovations that could be
attributed to Microsoft. Once I realized that Ctrl-Alt-Del
was handled in the BIOS, I found that there aren't any.


2002-01-09 16:55:46

by Michael Zhu

[permalink] [raw]
Subject: Re: About Loop Device

Thanks for the reply. But when I try to use the
command "mount -o loop /dev/fd0 /floppy", the mount
returns an error saying "mount: you must specify the
filesystem type". What is wrong? Thanks.

Michael


--- "Richard B. Johnson" <[email protected]>
wrote:
> On Wed, 9 Jan 2002, Michael Zhu wrote:
> [SNIPPED...]
>
> > connection between my own loop device with the
> floppy
> > disk? I mean how I can connect the loop device
> with
> > the floppy disk to hook the READ/WRITE operations
> to
> > the floppy disk.
> >
> > Michael
> >
>
> mount -o loop /dev/fd0 /mnt
>
> Cheers,
> Dick Johnson
>
> Penguin : Linux version 2.4.1 on an i686 machine
> (797.90 BogoMips).
>
> I was going to compile a list of innovations
> that could be
> attributed to Microsoft. Once I realized that
> Ctrl-Alt-Del
> was handled in the BIOS, I found that there
> aren't any.
>
>


______________________________________________________________________
Web-hosting solutions for home and business! http://website.yahoo.ca

2002-01-09 17:05:36

by Doug McNaught

[permalink] [raw]
Subject: Re: About Loop Device

Michael Zhu <[email protected]> writes:

> Thanks for the reply. But when I try to use the
> command "mount -o loop /dev/fd0 /floppy", the mount
> returns an error saying "mount: you must specify the
> filesystem type". What is wrong? Thanks.

You probably want losetup(8) instead of mount.

-Doug
--
Let us cross over the river, and rest under the shade of the trees.
--T. J. Jackson, 1863

2002-01-09 17:14:06

by Michael Zhu

[permalink] [raw]
Subject: Re: About Loop Device

Can you explain that detailed for me? I mean the whole
command I can use to connect the loop device and the
floppy disk.

Thanks.

Michael


--- Doug McNaught <[email protected]> wrote:
> Michael Zhu <[email protected]> writes:
>
> > Thanks for the reply. But when I try to use the
> > command "mount -o loop /dev/fd0 /floppy", the
> mount
> > returns an error saying "mount: you must specify
> the
> > filesystem type". What is wrong? Thanks.
>
> You probably want losetup(8) instead of mount.
>
> -Doug
> --
> Let us cross over the river, and rest under the
> shade of the trees.
> --T. J. Jackson, 1863


______________________________________________________________________
Web-hosting solutions for home and business! http://website.yahoo.ca

2002-01-09 17:21:17

by Doug McNaught

[permalink] [raw]
Subject: Re: About Loop Device

Michael Zhu <[email protected]> writes:

> Can you explain that detailed for me? I mean the whole
> command I can use to connect the loop device and the
> floppy disk.

Is there some problem with the manpage? Seems pretty clear to me.

-Doug
--
Let us cross over the river, and rest under the shade of the trees.
--T. J. Jackson, 1863

2002-01-09 17:32:36

by Michael Zhu

[permalink] [raw]
Subject: Re: About Loop Device

Hi, I just want to confirm whether the loop device can
encrypt the whole data on the disk even including the
boot sector. I want to make a whole block level
encryption. Thanks.

Michael

______________________________________________________________________
Web-hosting solutions for home and business! http://website.yahoo.ca

2002-01-09 17:40:17

by Richard B. Johnson

[permalink] [raw]
Subject: Re: About Loop Device

On Wed, 9 Jan 2002, Michael Zhu wrote:

> Hi, I just want to confirm whether the loop device can
> encrypt the whole data on the disk even including the
> boot sector. I want to make a whole block level
> encryption. Thanks.
>
> Michael

This may be a troll. How would you boot? Who decrypts during the
boot?

Cheers,
Dick Johnson

Penguin : Linux version 2.4.1 on an i686 machine (797.90 BogoMips).

I was going to compile a list of innovations that could be
attributed to Microsoft. Once I realized that Ctrl-Alt-Del
was handled in the BIOS, I found that there aren't any.


2002-01-09 20:06:27

by Ville Herva

[permalink] [raw]
Subject: Re: About Loop Device

On Wed, Jan 09, 2002 at 12:42:20PM -0500, you [Richard B. Johnson] claimed:
> On Wed, 9 Jan 2002, Michael Zhu wrote:
>
> > Hi, I just want to confirm whether the loop device can
> > encrypt the whole data on the disk even including the
> > boot sector. I want to make a whole block level
> > encryption. Thanks.
>
> This may be a troll. How would you boot? Who decrypts during the
> boot?

With a boot floppy, perhaps?


-- v --

[email protected]

2002-01-10 17:19:38

by Michael Zhu

[permalink] [raw]
Subject: Re: About Loop Device

Hi, now I can use the "mount -o loop /dev/fd0 /mnt" to
mount the loop device after I use mke2fs format the
/dev/fd0. But how can I test it? What are the
/dev/loop0,/dev/loop1.....,/dev/loop7 used for? Are
there any detailed informations about how to use the
loop device? I've read some souce code about the
loop.c file. But not fully understand. Can anyone give
me a hand on this. Thanks in advance.

Michael


On Wed, 9 Jan 2002, Michael Zhu wrote:

> Thanks for the reply. But when I try to use the
> command "mount -o loop /dev/fd0 /floppy", the mount
> returns an error saying "mount: you must specify the
> filesystem type". What is wrong? Thanks.
>
> Michael
>

man mount

mount -o loop -t ext2 /dev/fd0 /mnt # Usual linux
mount -o loop -t msdos /dev/fd0 /mnt # DOS
file-system
mount -o loop -t vfat /dev/fd0 /mnt # Win/NT, etc.
| | |__________
mount-point
| |_______________ device
|_________________________
File-system type




Cheers,
Dick Johnson

Penguin : Linux version 2.4.1 on an i686 machine
(797.90 BogoMips).

I was going to compile a list of innovations that
could be
attributed to Microsoft. Once I realized that
Ctrl-Alt-Del
was handled in the BIOS, I found that there aren't
any.


______________________________________________________________________
Web-hosting solutions for home and business! http://website.yahoo.ca

2002-01-10 21:47:44

by Michael Zhu

[permalink] [raw]
Subject: Re: About Loop Device

If I use those techniques, does it mean that I need to
add some patch to the kernel? I need to recompile the
kernel?

Michael


--- Gisle S?lensminde <[email protected]>
wrote:
>
> If you want to encrypt, the standard kernel is not
> sufficient, Instead,
> you should the cryptoapi
> og loop-aes modules, that is distributed separatly
> from the kernel. The
> Linux cryprography mailing
> list is probably of interest too
>
> Mailing list info:
>
> http://mail.nl.linux.org/linux-crypto/
>
> cryptoapi: http://cryptoapi.sourceforge.net
> loop-aes: http://loop-aes.sourceforge.net/
>
> Hope this helps.
>
> - Gisle
>


______________________________________________________________________
Web-hosting solutions for home and business! http://website.yahoo.ca