News for hackers. Stuff that matters.
Re:Looks like you are typing while in full screen by __s on Saturday April 24, 2021 @01:19PM (#26926582)
What prevents them is that it'd be within the confines of a website, so url bar tells you you're on a website & not the appstore asking for permission

This gets into sandboxes needing to have "sacred pixels" as a border to prevent the sandbox tricking the user into thinking they exited from the browser

This issues goes way back: imagine if after executing a program on CLI instead of closing it gave you a fake shell, where you eventually went about your day until you had to type your password into sudo..

Of course, your point about the app store is good motivation to address this, whereas consoles don't go about offering much protection there

Re:Looks like you are typing while in full screen by rsa25519 on Saturday April 24, 2021 @02:58PM (#26927400)
> This issues goes way back: imagine if after executing a program on CLI instead of closing it gave you a fake shell, where you eventually went about your day until you had to type your password into sudo..

As a fun fact, even worse might be a program maliciously aliasing sudo in ~/.profile

Re:Looks like you are typing while in full screen by spicybright on Saturday April 24, 2021 @06:42PM (#26928837)
That's a spooky one, although I've never heard of that happening in practice before.

But then again how, how someone know if that happened!

Re:Looks like you are typing while in full screen by moistbar on Saturday April 24, 2021 @07:32PM (#26929128)
They'd have to know to look for it, but running `alias sudo` would show if it had an alias assigned to it. It would honestly be more effective to change $PATH to include the malicious version of sudo.
Re:Looks like you are typing while in full screen by akersten on Saturday April 24, 2021 @01:24PM (#26926618)
> , so url bar tells you you're on a website

Is this even the case anymore? On Android, all my URL bars peel up into the top of the screen as I browse, and I'm pretty sure a website can capture the vertical swipe/arrange an inner-scrolling element to make it very difficult to quickly get the URL bar visible again.

I think that would be enough to trick most users. This seems like an unnecessary limitation

Re:Looks like you are typing while in full screen by saurik on Saturday April 24, 2021 @01:38PM (#26926734)
This is iOS, though, where the URL bar is always at least minimally present.
Re:Looks like you are typing while in full screen by t0mas88 on Saturday April 24, 2021 @02:10PM (#26927014)
On safari, but not on for example Edge for iOS or Chrome for iOS.
Re:Looks like you are typing while in full screen by jereees on Saturday April 24, 2021 @04:34PM (#26928077)
Huh. I’m surprised apple didn’t make it a requirement before approving those apps into their store given how strong their stance on privacy is.
Re:Looks like you are typing while in full screen by ogre_codes on Saturday April 24, 2021 @03:33PM (#26927645)
Is this security feature present on Edge or Chrome on iOS?
Re:Looks like you are typing while in full screen by toxik on Saturday April 24, 2021 @03:29PM (#26927621)
Which is a good reminder that password entry is terrible security wise. With macOS, you can sudo authenticate with your Apple Watch, which is really nice.
Re:Looks like you are typing while in full screen by majewsky on Saturday April 24, 2021 @03:46PM (#26927745)
If you're concerned that a script's root password prompt may be a forgery, you can run "sudo -v" before executing the script.

For background, there is a convenience feature in sudo: It only requires your password prompt if you have not had a successful sudo invocation in the same terminal in the last X minutes (5 minutes, I think? not sure on the exact value). "sudo -v" is a special invocation which does not actually execute any command, but it renews your 5-minute lease. ("sudo true" is effectively equivalent, though not idiomatic.)

So if you're executing a short script that needs sudo, run "sudo -v" before running the actual script. Then you know that if a root password prompt pops up again, it's not really sudo who's asking.

Re:Looks like you are typing while in full screen by gruez on Saturday April 24, 2021 @04:09PM (#26927912)
> If you're concerned that a script's root password prompt may be a forgery, you can run "sudo -v" before executing the script.

The bigger problem is that even without sudo or your root password, malicious scripts can do a lot of damage. ie. they can add a fake sudo to your .profile, so you next time you try to do "sudo -v" your password still gets stolen.

Re:Looks like you are typing while in full screen by jereees on Saturday April 24, 2021 @04:35PM (#26928081)
Is this a feature built in into the OS? I have only heard of some third party code to allow that…
Re:Looks like you are typing while in full screen by toxik on Sunday April 25, 2021 @06:32AM (#26931687)
It's not built-in for sudo, which is surprising. It is however for many other authentication prompts.