Jump to content

Archived

This topic is now archived and is closed to further replies.

troyhunt

Can't install infusions to USB

Recommended Posts

Hi guys, I'm struggling to get infusions installed to USB despite everything looking like it checks out just fine. Bear with me:

USB is formatted for ext4 and shows up just fine under lsusb. I can SSH in and write to /usb without issue so all looks fine on that front.

When I install infusions, there's only an option to install to internal storage. I'm not seeing USB anywhere and I'm not sure if it's because I'm missing something or if I'm just not supposed to and I'm simply doing it wrong.

Ideas?

Share this post


Link to post
Share on other sites

Hi guys, I'm struggling to get infusions installed to USB despite everything looking like it checks out just fine. Bear with me:

USB is formatted for ext4 and shows up just fine under lsusb. I can SSH in and write to /usb without issue so all looks fine on that front.

When I install infusions, there's only an option to install to internal storage. I'm not seeing USB anywhere and I'm not sure if it's because I'm missing something or if I'm just not supposed to and I'm simply doing it wrong.

Ideas?

Double check your fstab with Darrens post, and check that your USB drive is being powered fully, some people have problems powering with sticks larger than 4GB.

-Foxtrot

Share this post


Link to post
Share on other sites

Double check your fstab with Darrens post, and check that your USB drive is being powered fully, some people have problems powering with sticks larger than 4GB.

-Foxtrot

I followed Darren's post on three different drives (one at 4GB) with the same result. Device is running from AC mains and firmware is on 2.8. I'm just a bit suspicious that I can read and write to the drive just fine (and can probably just manually install the infusion if necessary) but can't install to it from the browser.

Share this post


Link to post
Share on other sites

I followed Darren's post on three different drives (one at 4GB) with the same result. Device is running from AC mains and firmware is on 2.8. I'm just a bit suspicious that I can read and write to the drive just fine (and can probably just manually install the infusion if necessary) but can't install to it from the browser.

The web-interface check your mounts.

run the "mount" command and report it's output please.

Share this post


Link to post
Share on other sites

I ran swapoff -a && swapon –a, then re-created the swap partition, and it is working now. I had the same issue. Not sure if I just got lucky or if this works.

Share this post


Link to post
Share on other sites

run the "mount" command and report it's output please.

Here's what I'm seeing - missing something? Guessing that's a "yes" with no USB records.

Execute: mount
rootfs on / type rootfs (rw)
/dev/root on /rom type squashfs (ro,relatime)
proc on /proc type proc (rw,noatime)
sysfs on /sys type sysfs (rw,noatime)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev,noatime,size=14668k)
tmpfs on /dev type tmpfs (rw,noatime,size=512k,mode=755)
devpts on /dev/pts type devpts (rw,noatime,mode=600)
/dev/mtdblock3 on /overlay type jffs2 (rw,noatime)
overlayfs:/overlay on / type overlayfs (rw,noatime,lowerdir=/,upperdir=/overlay)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
/dev/sda5 on /mnt/sda5 type ext4 (rw,relatime,data=ordered)
/dev/sda6 on /mnt/sda6 type ext4 (rw,relatime,data=ordered)

Share this post


Link to post
Share on other sites

Here's what I'm seeing - missing something? Guessing that's a "yes" with no USB records.

Execute: mount
rootfs on / type rootfs (rw)
/dev/root on /rom type squashfs (ro,relatime)
proc on /proc type proc (rw,noatime)
sysfs on /sys type sysfs (rw,noatime)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev,noatime,size=14668k)
tmpfs on /dev type tmpfs (rw,noatime,size=512k,mode=755)
devpts on /dev/pts type devpts (rw,noatime,mode=600)
/dev/mtdblock3 on /overlay type jffs2 (rw,noatime)
overlayfs:/overlay on / type overlayfs (rw,noatime,lowerdir=/,upperdir=/overlay)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
/dev/sda5 on /mnt/sda5 type ext4 (rw,relatime,data=ordered)
/dev/sda6 on /mnt/sda6 type ext4 (rw,relatime,data=ordered)

Your mounts are goofy. How many partitions do you have on your usb drive??

Here's what mine looks like, I have /usb mounted to sda2 not 1, but other than that it's a standard mount.

Execute: mount
rootfs on / type rootfs (rw)
/dev/root on /rom type squashfs (ro,relatime)
proc on /proc type proc (rw,noatime)
sysfs on /sys type sysfs (rw,noatime)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev,noatime,size=14668k)
tmpfs on /dev type tmpfs (rw,noatime,size=512k,mode=755)
devpts on /dev/pts type devpts (rw,noatime,mode=600)
/dev/mtdblock3 on /overlay type jffs2 (rw,noatime)
overlayfs:/overlay on / type overlayfs (rw,noatime,lowerdir=/,upperdir=/overlay)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
/dev/sda2 on /usb type ext4 (rw,sync,relatime,data=ordered)

Share this post


Link to post
Share on other sites

Here's what I'm seeing - missing something? Guessing that's a "yes" with no USB records.

Execute: mount
rootfs on / type rootfs (rw)
/dev/root on /rom type squashfs (ro,relatime)
proc on /proc type proc (rw,noatime)
sysfs on /sys type sysfs (rw,noatime)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev,noatime,size=14668k)
tmpfs on /dev type tmpfs (rw,noatime,size=512k,mode=755)
devpts on /dev/pts type devpts (rw,noatime,mode=600)
/dev/mtdblock3 on /overlay type jffs2 (rw,noatime)
overlayfs:/overlay on / type overlayfs (rw,noatime,lowerdir=/,upperdir=/overlay)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
/dev/sda5 on /mnt/sda5 type ext4 (rw,relatime,data=ordered)
/dev/sda6 on /mnt/sda6 type ext4 (rw,relatime,data=ordered)

Yeah, see:

It doesn't mount to /usb/ at all.

Could you post your /etc/fstab?

Share this post


Link to post
Share on other sites
config global automount
option from_fstab 1
option anon_mount 1
config global autoswap
option from_fstab 1
option anon_swap 0
config mount
option target /usb
option device /dev/sda1
option fstype ext4
option options rw,sync
option enabled 1
option enabled_fsck 0
config swap
option device /dev/sda2
option enabled 0

Should look something like the above.

Share this post


Link to post
Share on other sites

Your mounts are goofy. How many partitions do you have on your usb drive??

Just the two per Darren's guidance with one intended to be a swap file.

It doesn't mount to /usb/ at all.

Could you post your /etc/fstab?

Here's what I'm seeing:

config global automount
       option from_fstab 1
       option anon_mount 1


config global autoswap
       option from_fstab 1
       option anon_swap 0


config mount
       option target   /usb
       option device   /dev/sda1
       option fstype   ext4
       option options  rw,sync
       option enabled  1
       option enabled_fsck 0


config swap
       option device   /dev/sda2
       option enabled  1

Anything there look odd?

Share this post


Link to post
Share on other sites

Your fstab looks correct - still, it seems like you have more than just two partitions.

Can you execute an "ls -la /dev/sd*" and post that? If you see more than /dev/sda1 and /dev/sda2 then you need to re-format your drive. If your partition program shows only two partitions, maybe try a different tool - a different member recently had the issue that his wizard was creating sub partitions just like yours seems to be doing.

Share this post


Link to post
Share on other sites

Can you execute an "ls -la /dev/sd*" and post that? If you see more than /dev/sda1 and /dev/sda2 then you need to re-format your drive. If your partition program shows only two partitions, maybe try a different tool - a different member recently had the issue that his wizard was creating sub partitions just like yours seems to be doing.

Here's what I'm seeing:

root@Pineapple:~# ls -la /dev/sd*
brw-r--r--    1 root     root        8,   0 Jan  1  1970 /dev/sda
brw-r--r--    1 root     root        8,   1 Jan  1  1970 /dev/sda1
brw-r--r--    1 root     root        8,   5 Jan  1  1970 /dev/sda5
brw-r--r--    1 root     root        8,   6 Jan  1  1970 /dev/sda6

So yeah, probably a bit too much going on there! I've been formatting with MiniTool Partition Wizard on Windows (probably obviously Linux is not my daily by now), so that might be it. I'll grab a spare Linux VM from somewhere and format from there, seems like a few others have had issues so worth capturing the result here for future reference. I'll update shortly.

Share this post


Link to post
Share on other sites

Here's what I'm seeing:

root@Pineapple:~# ls -la /dev/sd*
brw-r--r--    1 root     root        8,   0 Jan  1  1970 /dev/sda
brw-r--r--    1 root     root        8,   1 Jan  1  1970 /dev/sda1
brw-r--r--    1 root     root        8,   5 Jan  1  1970 /dev/sda5
brw-r--r--    1 root     root        8,   6 Jan  1  1970 /dev/sda6

So yeah, probably a bit too much going on there! I've been formatting with MiniTool Partition Wizard on Windows (probably obviously Linux is not my daily by now), so that might be it. I'll grab a spare Linux VM from somewhere and format from there, seems like a few others have had issues so worth capturing the result here for future reference. I'll update shortly.

Yup, that was the name of it! Yeah, it seems to cause nested partitions. I am sure it is possible to use that but change some settings.. or get a different partition wizard ;)

But this should solve your issue, I am glad you are on your way to getting things up and running!

Share this post


Link to post
Share on other sites

Thanks very much everyone who provided assistance here, the problem was indeed the way the drive was partitioned from Windows. I fired up an Ubuntu LiveCD and did it again which fixed the issue right up.

For reference, I've written about the process in more detail on my blog under The beginners guide to breaking website security with nothing more than a Pineapple. I'll be using the device in a bunch of different blogging and training contexts to help developers get their TLS right, perfect tool for the job!

Share this post


Link to post
Share on other sites

Thanks very much everyone who provided assistance here, the problem was indeed the way the drive was partitioned from Windows. I fired up an Ubuntu LiveCD and did it again which fixed the issue right up.

For reference, I've written about the process in more detail on my blog under The beginners guide to breaking website security with nothing more than a Pineapple. I'll be using the device in a bunch of different blogging and training contexts to help developers get their TLS right, perfect tool for the job!

Nice post! I really like the details you have gone into!

Just one thing: You link to the source code of the web-ui. That is far outdated and just a clone of our old repository. You can find the new one here.

Share this post


Link to post
Share on other sites

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...