Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 10451 10452 [10453] 10454 10455 ... 11037

Author Topic: Things that made you go "WTF?" today o_O  (Read 14545594 times)

wierd

  • Bay Watcher
  • I like to eat small children.
    • View Profile
Re: Things that made you go "WTF?" today o_O
« Reply #156780 on: April 23, 2021, 11:16:00 pm »

For an SSD, you can always cobble together a shell script that gets the total drive size in bytes (and the physical sector size) by probulating the /sys block, then invokes dd with /dev/urandom as the source, that runs a few times through.

Overwriting every single cluster repeatedly will assure that every cluster is overwritten, even with wear leveling. 

Flash technology works through basically trapping electrons inside a logic gate through tunneling.  If you succeed in overwriting the state of the gate you have succeeded in overwriting the state of the gate.  It does not leave ghost magnetic domain remnants like a magnetic medium does, so forensic recovery is much more difficult.
Logged

methylatedspirit

  • Bay Watcher
  • it/its
    • View Profile
Re: Things that made you go "WTF?" today o_O
« Reply #156781 on: April 24, 2021, 12:16:42 am »

Why not do the classic dd if=/dev/urandom of=/dev/sdf bs=512 a couple of times instead of that mess of finding the total disk space first? It's easier, and dd stops when it runs out of disk space.

Or, if you just want to zero off empty blocks (but only in ext2, ext3 and ext4), why not just use zerofree? It's not really the intended use case, but it's a plausible non-destructive, non-total-wipe shredding method for SSDs, if I've understood the man pages right. Delete the files you want to shred, then run zerofree. You'll need to unmount/mount read-only the disk you want to zero off the empty blocks of, though. I would not call this method safe, even if the theory holds up.
Logged

EuchreJack

  • Bay Watcher
  • Lord of Norderland - Lv 20 SKOOKUM ROC
    • View Profile
Re: Things that made you go "WTF?" today o_O
« Reply #156782 on: April 24, 2021, 12:25:01 am »

Hey, I got a lake near where I live.  All my computers either stay with me eternally, or go into the lake.  I'm good.

EDIT: Or they outlive me, in which I simply don't care since I'm dead:P

wierd

  • Bay Watcher
  • I like to eat small children.
    • View Profile
Re: Things that made you go "WTF?" today o_O
« Reply #156783 on: April 24, 2021, 12:46:44 am »

Why not do the classic dd if=/dev/urandom of=/dev/sdf bs=512 a couple of times instead of that mess of finding the total disk space first? It's easier, and dd stops when it runs out of disk space.

Or, if you just want to zero off empty blocks (but only in ext2, ext3 and ext4), why not just use zerofree? It's not really the intended use case, but it's a plausible non-destructive, non-total-wipe shredding method for SSDs, if I've understood the man pages right. Delete the files you want to shred, then run zerofree. You'll need to unmount/mount read-only the disk you want to zero off the empty blocks of, though. I would not call this method safe, even if the theory holds up.

Two words:

Write Amplification

You want to know what the native sector size is, and the info in /sys will tell you that.  This is the value you should feed for BS= so that dd writes with the correct granularity.
Logged

methylatedspirit

  • Bay Watcher
  • it/its
    • View Profile
Re: Things that made you go "WTF?" today o_O
« Reply #156784 on: April 24, 2021, 01:19:13 am »

Hey, I got a lake near where I live.  All my computers either stay with me eternally, or go into the lake.  I'm good.

EDIT: Or they outlive me, in which I simply don't care since I'm dead:P

Somehow, I don't imagine you having been exposed to the paranoid shit I've seen. If you want a small taste, go to the Arch Wiki's page on Security and The paranoid #! Security Guide; it's extensive. It's mostly Linux-specific, but I think I felt the paranoia even as a Windows user. And those mostly revolve around the technical side of things. I remember reading general security stuff a while ago, which was even more balls-to-the-wall paranoid, but I can't find it now.

Two words:

Write Amplification

*shudders*

I'm convinced now. So if you're as lazy as I am, just do sudo fdisk -l and read off the physical sector size, right? Does that give you the correct bs= value?
« Last Edit: April 24, 2021, 01:22:08 am by methylatedspirit »
Logged

King Zultan

  • Bay Watcher
    • View Profile
Re: Things that made you go "WTF?" today o_O
« Reply #156785 on: April 24, 2021, 03:04:38 am »

If your paranoid about people getting what's on your computer why not just set it on fire, or throw it off a pier into the ocean, or you know just hit it with a hammer until it's dead?
Logged
The Lawyer opens a briefcase. It's full of lemons, the justice fruit only lawyers may touch.
Make sure not to step on any errant blood stains before we find our LIFE EXTINGUSHER.
but anyway, if you'll excuse me, I need to commit sebbaku.
Quote from: Leodanny
Can I have the sword when you’re done?

wierd

  • Bay Watcher
  • I like to eat small children.
    • View Profile
Re: Things that made you go "WTF?" today o_O
« Reply #156786 on: April 24, 2021, 03:05:51 am »

Depends on how sane the SSD is.  Ideally, you want to get the erase unit size.

At least for something like an eMMC, you find it in /sys:

/sys/block/mmcblk1/device/erase_size

Give me a bit to slap in a USB stick, (which gets arbitrated as a scsi disk)-- and see what shows up.


Nope, no clear and easy way to determine the erase block size from a scsi disk. At least, not from USB connected ones.  Voodoo with flashbench is probably the only way to derive it.
« Last Edit: April 24, 2021, 03:24:51 am by wierd »
Logged

methylatedspirit

  • Bay Watcher
  • it/its
    • View Profile
Re: Things that made you go "WTF?" today o_O
« Reply #156787 on: April 24, 2021, 04:04:30 am »

Nope, no clear and easy way to determine the erase block size from a scsi disk. At least, not from USB connected ones.  Voodoo with flashbench is probably the only way to derive it.

All I'm hearing right now is "WELCOME TO COMMAND-LINE HELL, FUCKER!". I'm looking at the GitHub, and all I'm thinking right now is "Oh god, do I really have to stare at this shit just to understand what's going on with my flash devices?". Oh well, I've acquired working knowledge of FFmpeg by databending, may as well learn some more command-line utilities. It'll get less painful over time.

-------

As a sidenote, wierd, if I may ask, what OSes do you use? Like, you seem to have really good technical knowledge of Windows, Linux, as well as the underlying components that allow them to work in the first place. I don't know where you keep pulling all this incredibly detailed knowledge from; you seem like you've studied or worked with computers for decades. At this point, if you said that you wrote your own OS (kernel, filesystem, GUI and all), and then made it self-hosting, I wouldn't even be surprised.
Logged

wierd

  • Bay Watcher
  • I like to eat small children.
    • View Profile
Re: Things that made you go "WTF?" today o_O
« Reply #156788 on: April 24, 2021, 04:14:58 am »

I am old.  I will be 40 next year.

I have been working with computers since I was only enough to use one.  I have very detailed knowledge of DOS, WIndows (from 3x through modern), Linux, Classic macintosh, and a smattering of OSX knowledge.  I can also make android phones do loopty loops.

I also know how to do network administration, and SAN administration.

(In addition to knowing how to drive an industrial CAD seat.)


I am one of those "overqualified" workers, working at a job that involves actual shit, simply because it is a very different kind of stress that I handle better.  Those corporate assfuckers can go fuck a donkey. (Top, Bottom, I don't care.) 


Rather than try to reinvent the wheel when it comes to reconditioning an SSD, I would suggest using smartctl or hdparm, to initiate a secure erase process on the SSD.  The SMART firmware inside the SSD **SURELY** knows the secret sauce size of the erase block, and will zero-fill for you appropriately. (and if it does not, you have bigger problems on your hands, because it means your SSD was assembled by idiots.)

Setting the drive up again correctly would require you to determine the erase block all the same though, so learning the voodoo with flashbench is probably in your best interests.
Logged

methylatedspirit

  • Bay Watcher
  • it/its
    • View Profile
Re: Things that made you go "WTF?" today o_O
« Reply #156789 on: April 24, 2021, 05:44:24 am »

If your paranoid about people getting what's on your computer why not just set it on fire, or throw it off a pier into the ocean, or you know just hit it with a hammer until it's dead?

I'll quote the Arch Linux wiki:
Quote
• It is possible to tighten security to the point where the system is unusable. Security and convenience must be balanced. The trick is to create a secure and useful system.
• You can never make a system 100% secure unless you unplug the machine from all networks, turn it off, lock it in a safe, smother it in concrete and never use it.

You must do your best, but perfection is impossible. That's the name of the game in paranoid security. If you're that paranoid, and really want to reject computing outright for security reasons, go ahead, but it's not possible to live in the modern world without encountering a computer at least once a day. Best you can do is to minimize your risk as much as humanly possible while still being able to do stuff.

And said wiki pretty much tells you that your security will fail at some point, and that you're the most likely point of failure:
Quote
• Prepare for failure. Create a plan ahead of time to follow when your security is broken.
• The biggest threat is, and will always be, the user.

I wouldn't be able to do this. I'd break long before whatever security I set up gets broken.
Logged

ArchimedesWojak

  • Bay Watcher
    • View Profile
Re: Things that made you go "WTF?" today o_O
« Reply #156790 on: April 25, 2021, 08:14:38 am »

« Last Edit: April 25, 2021, 08:18:36 am by ArchimedesWojak »
Logged
YET ANOTHER DATA-COLLECTION THREAD FROM MR. "NOT FEDERAL AUTHORITIES."
ArchimedesWojak is very militant against zoophilia due to his deeply held religious beliefs.

None

  • Bay Watcher
  • Forgotten, but not gone
    • View Profile
Re: Things that made you go "WTF?" today o_O
« Reply #156791 on: April 25, 2021, 08:53:47 am »

Hey, I got a lake near where I live.  All my computers either stay with me eternally, or go into the lake.  I'm good.

EDIT: Or they outlive me, in which I simply don't care since I'm dead:P

As a hobbyist magnet fisher, I'm looking forward to the day I pull a computer out of a lake. Recycle that shit, yo.
Logged

methylatedspirit

  • Bay Watcher
  • it/its
    • View Profile
Re: Things that made you go "WTF?" today o_O
« Reply #156792 on: April 25, 2021, 10:09:44 am »

I dunno how, but a roommate of mine keeps getting food seemingly out of the blue and giving them to me. I realize it's Ramadan (which I begrudgingly comply with; I can't fake dehydration), and the campus mosque is giving out food, but it's happening at a suspiciously-high rate. How the hell is he getting this food so often? Do people just not want to eat right after fasting 13 hours straight?
Logged

Yellow Pixel

  • Bay Watcher
    • View Profile
Re: Things that made you go "WTF?" today o_O
« Reply #156793 on: April 25, 2021, 01:30:39 pm »

Or maybe your roommate is affected by the Ramadan hamster syndrome? :P
Logged

methylatedspirit

  • Bay Watcher
  • it/its
    • View Profile
Re: Things that made you go "WTF?" today o_O
« Reply #156794 on: April 25, 2021, 02:07:06 pm »

I can't say I remember that term, but it's the one where people just overeat to a ridiculous extent when they're allowed to eat, right? I think I suffer from the water version of that. Can't say I'm too successful at that one. I'm gonna come out of this with a massive salt craving or pica to satisfy it. I'm already looking longingly at salt online.
Logged
Pages: 1 ... 10451 10452 [10453] 10454 10455 ... 11037