[-] vvv@programming.dev 48 points 18 hours ago
[-] vvv@programming.dev 2 points 5 days ago

Updoots for The 4400. Might be my favorite show of all time. The theme song is still playing in my head.

Do /not/ make the mistake of watching the cw's 4400 (without a The). I would rather watch Tommy Wiseau's The Neighbors over it.

[-] vvv@programming.dev 3 points 6 days ago

Add Tucker and Dale vs Evil to that category.

[-] vvv@programming.dev 79 points 1 month ago

.... but cd is a built-in

[-] vvv@programming.dev 27 points 4 months ago* (last edited 4 months ago)

... but there is a way, and it has been proven.

One of the more memorable physics classes I've had went into the history of discoveries that led to our understanding of relativity. The relevant story here, starts with how sound travels though air.

Let's say you're standing at the bottom of a building shouting to your friend peeking out a window on the 5th floor. On a calm day, that friend will hear you at pretty much the same time as someone standing the same distance away, but on the street. However, if it's windy, the wind pushes around the air through which the sound of your voice is traveling, the friend up in the window will have a slight delay in receiving that sound. This can of course be verified with more scientific rigor, like a sound sent in two perpendicular directions activating a light.

Scientist at the time thought that light, like sound, must travel though some medium, and they called this theoretical medium the Aether. Since this medium is not locked to Earth, they figured they must be capable of detecting movement of this medium, an Aether wind, if you will. If somehow the movement of this medium caused the speed of light in one direction to be faster than another due to the movement of this medium, measuring the speed in two directions perpendicular to each other would reveal that difference. After a series of experiments of increasing distances and measurement sensitivities (think mirrors on mountain tops to measure the time for a laser beam to reflect), no change in the speed of light based on direction was found.

Please enjoy this wikipedia hole: https://en.m.wikipedia.org/wiki/Michelson%E2%80%93Morley_experiment , and please consider a bit of caution before you refer to things as facts in the future!

16

Somewhere between API resources, queue workers, repositories, clients and serializers there is a class of ... classes/modules that does the needful. Gun-to-my-head, I would call them "services" but I'm looking for a less overloaded term. Maybe capabilities? Controllers? Pick a term from the business domain? What do you call them?

[-] vvv@programming.dev 57 points 5 months ago

grep -r exists and is even more faster and doesn't require passing around file names.

grep -r --include='*.txt' 'somename' .
[-] vvv@programming.dev 50 points 6 months ago* (last edited 6 months ago)

(obligatory I'm not a network surgeon this is likely not perfectly correct)

The article mentions network interfaces, DHCP and gateways so real quick: a network interface usually represents a physical connection to a network, like an Ethernet port or a WiFi card. DHCP is a protocol that auto configured network routes and addresses once a physical connection is established, like when you jack in via an ethernet cable, it tells you the IP address you should go by, the range of IP address on the network you've connected to, where you can resolve domain names to IP addresses. It also tells you the address of a default gateway to route traffic to, if you're trying to reach something outside of this network.

You can have more than one set of this configuration. Your wired network might tell you that your an address is 10.0.0.34, anything that starts with 10.0.0. is local, and to talk to 10.0.0.254 if you're trying to get to anything else. If at the same time you also connect to a wireless network, that might tell you that your address is 192.168.0.69, 192.168.0.* is your local network, and 192.168.0.254 is your gateway out. Now your computer wants to talk to 4.2.2.2. Should it use the wireless interface and go via 192.168.0.254? or the wired one and use 10.0.0.254? Your os has a routing table that includes both of those routes, and based on the precedence of the entries in it, it'll pick one.

VPN software usually works by creating a network interface on your computer, similar to an interface to a WiFi card, but virtual. It then asks the OS to route all network traffic, through the new interface it created. Except of course traffic from the VPN software, because that still needs to get out to the VPN provider (let's say, at 1.3.3.7) via real Internet.

So if you're following along at home, your routing table at this point might look like this:

  • traffic to 1.3.3.7 should go to 10.0.0.254 via the wired interface
  • all traffic should go to the VPN interface
  • traffic to 10.0.0.* should go to the wired interface
  • all traffic should go to 10.0.0.254 via the wired interface
  • traffic to 192.168.0.* should go to the wireless interface
  • all traffic should go to 192.168.0.254 via the wireless interface

whenever your os wants to send network packets, it'll go down this list of rules until one applies. With that VPN turned on, most of the time, only those two first rules will ever apply.

If I'm reading the article correctly, what this attack does, is run a DHCP server, that when handing out routing rules, will send one with a flag that causes, for example, the last two rules to be placed at the top of the list instead of the bottom. Your VPN will still be on, the configuration it's requested the OS to make would still be in place, and yet all your traffic will be routed out to this insecure wireless network that's somehow set itself as the priority route over anything else.

[-] vvv@programming.dev 82 points 7 months ago

just to add a little more explanation to what the other posters are suggesting.... a hard drive, from the perspective of your OS is very very simple. it's a series of bytes. for the sake of this example, let's say there are 1000 of them. they are just a series of numbers.

how do you tell apart which numbers belong to which partitions? well there's a convention: you decide that the first 10 of those numbers can be a label to indicate where partions start. e.g. your efi starts at #11 and ends at #61. root at starts at #61 and ends at #800. the label doesn't say anything about the bytes after that.

how do you know which bytes in the partions make up files? similar sort of game with a file system within the bounds of that partion - you use some of the data as a label to find the file data. maybe bytes 71-78 indicate that you can find ~/.bash_histor at bytes 732-790.

what happened when you shrunk that root partions, is you changed that label at the beginning. your root partion, it says, now starts at byte #61 and goes to #300. any bytes after that, are fair game for a new partion and filesystem to overwrite.

the point of all this, is that so far all you've done is changed some labels. the bytes that make up your files are still on the disk, but perhaps not findable. however - because every process that writes to the disk will trust those labels, any operation you do to the disk, including mounting it has a chance to overwrite the data that makes up your files.

this means:

  • most of your files are probably recoverable
  • do not boot the operating system on that drive, or any other that will attempt to mount it, because you risk overwring data
  • before you start using any data recovery tools, make a copy of the raw bytes of the disk to a different disk, so that if the tools mess up you have an option to try again

ONLY after that is done, the first thing I'd try is setting that partion label back to what it used to say, 100gb.. if you're lucky, everything will just work. if you aren't, tools like 'photorec' can crawl the raw bytes of the disk and try and output whatever files they find.

good luck!

79
submitted 7 months ago* (last edited 7 months ago) by vvv@programming.dev to c/selfhosted@lemmy.world

Hi! I'm swapping my daily android phone for the nth time today and going through my set-up "check-list". As apps are updating/installing, I thought I'd check in with the hive-mind, what are you all doing to make the process easier? Maybe you know of a way to self-host some sort of android profile server? I'll post my process + list of goals & gripes below and if you have any tips or suggestions about what I can do better, I'd love to hear them!!

Current Process

  • flash clean rom
  • walk through the setup process
  • enable developer mode + adb
  • go through default app list disabling/uninstalling crap i don't want
  • use 'fdroidcl' to install all my fdroid apps
  • adb push a gpg private key to import into OpenKeychain
  • generate a ssh keypair in Password Store, put public key on my server via ConnectBot, clone passwords repo
  • log into firefox sync
  • log into joplin
  • configure fairmail
  • configure davx
  • log in to google account
  • download play store apps I was missing
  • go through apps one by one, logging in to accounts + doing configuration
  • deal with fucking whatsapp
  • hold old phone + new phone side by side and made sure i got everything

Goals & Gripes

App Installation

fdroidcl helps a LOT here, i can have a list of my minimal required packages - password management solution, browser, and notes get installed and it solves a lot of bootstrapping problems for me. I never need to do the dance of opening chrome, downloading fdroid, giving chrome install permissions, installing fdroid, etc.

that said, it is /slow/ and obviously limited to installing apps from fdroid repositories. maybe the slowness i can solve with self-hosting an fdroid repo, but i'm still stuck with having to install a bunch of apps manually either through aurora store, or play store.

App configuration

If i could push in arbitrary app configurations i would be sooooo happy. certain apps have config export/import, like my launcher, but that's far from all of them. i've tried a number of "backup" options, like Titanium, but obviously they don't work without root and don't always work /with/ root, especially going across devices. I've vaguely considered using Appium for this but ... ehhhh.

De-googling

Okay, so I can probably solve the apk problem somehow... I can solve the contacts sync... but I really like android auto, and that's a non-starter without a system google account afaik.

Whatsapp

i've never once managed to successfully move whatsapp to another device and not lose my chat history. it starts restoring from a backup, fails, and kicks me into being logged in without any chance of a restore.

Edit: oh and if you have any suggestion that'd make me not hate re-pairing wearos watch... 🥺

[-] vvv@programming.dev 27 points 7 months ago

Another way of writing '10'

[-] vvv@programming.dev 29 points 7 months ago

something to consider here... Firefox lazy-loads out of focus tabs when you start it, so if you're a tab hoarder, it's nice for just the one active tab per window to load when you start the browser.

I'm not sure that you can get it to do the same with "out of focus" windows. or maybe I have a tab hoarding problem.

[-] vvv@programming.dev 24 points 8 months ago

Gen 2 chevy volt owner here, PHEVs are absolutely not a step back. If I didn't buy the volt, the one car our family could afford would have been an ICE car. IMO, these things help bridge idealism with current reality - for most of my day-to-day, I drive a fully electric car. I just also get the option to toss some gas into it when on a long road trip.

[-] vvv@programming.dev 159 points 9 months ago

it's awful and I hate it. I generally prefer not to have a shared identity across communities, and there's no way to create a usable discord identity without a phone number.

45
My carryonable 3d printer (blog.ofvlad.xyz)

I've posted this to reddit before, but the post has gotten lost among an automod flurry. I've got some longer travel coming up and this thing has been on my mind again, so I'm looking for some suggestions!

0
submitted 1 year ago by vvv@programming.dev to c/asklemmy@lemmy.ml

An example: https://www.thenextdroid.com/topics/tutorials/root/. This Ellis Gibson person. Very good with the find/replace button.

Maybe you know of a browser extension to hide all these?

view more: next ›

vvv

joined 1 year ago