Recently posted comments
GNOME 3.32 released
Posted Mar 14, 2019 19:51 UTC (Thu) by josh (subscriber, #17465)Parent article: GNOME 3.32 released
Cook: security things in Linux v5.0
Posted Mar 14, 2019 18:49 UTC (Thu) by tdz (subscriber, #58733)In reply to: Cook: security things in Linux v5.0 by rweikusat2
Parent article: Cook: security things in Linux v5.0
I don't see anything wrong with this. Of all the changes from the linked article, this is the least controversial. This has no runtime/compile overhead or any form of weird semantics. It doesn't obfuscate the code base. This change has zero negative impact. If anything, I'd ask for using the related gcc attribute instead of a comment.
Fixing programmers
Posted Mar 14, 2019 18:31 UTC (Thu) by HelloWorld (guest, #56129)In reply to: Fixing programmers by rweikusat2
Parent article: Cook: security things in Linux v5.0
How is a "fallthrough comment" at the end of a case branch not a language extension, assuming that its presence is enforced by the compiler?
Besides, this has been standardized in C++17. The only reason it's not in C is that the C committee is run by a bunch of stick-in-the-muds.
Fixing programmers
Posted Mar 14, 2019 17:53 UTC (Thu) by Cyberax (✭ supporter ✭, #52523)In reply to: Fixing programmers by rweikusat2
Parent article: Cook: security things in Linux v5.0
A cavalier attitude of ignoring the simplest safety features has led the industry down the never-ending rabbit hole of security bugs.
Python dictionary "addition" and "subtraction"
Posted Mar 14, 2019 17:17 UTC (Thu) by NYKevin (subscriber, #129325)In reply to: Python dictionary "addition" and "subtraction" by nybble41
Parent article: Python dictionary "addition" and "subtraction"
Fixing programmers
Posted Mar 14, 2019 16:34 UTC (Thu) by rweikusat2 (subscriber, #117920)In reply to: Fixing programmers by dottedmag
Parent article: Cook: security things in Linux v5.0
In theory, we're past the point were "Charge and beat 'em!" was an acceptable discussion tactic.
Fixing programmers
Posted Mar 14, 2019 16:31 UTC (Thu) by rweikusat2 (subscriber, #117920)In reply to: Fixing programmers by Cyberax
Parent article: Cook: security things in Linux v5.0
Switching the topic of a discussion away from something technical and towards posting speculative, public insults about people who happen to disagree with some opinion is not a strong point in favour of this opinion. Rather the opposite.
Fixing programmers
Posted Mar 14, 2019 16:19 UTC (Thu) by rweikusat2 (subscriber, #117920)In reply to: Fixing programmers by epa
Parent article: Cook: security things in Linux v5.0
Fixing programmers
Posted Mar 14, 2019 15:42 UTC (Thu) by Wol (subscriber, #4433)In reply to: Fixing programmers by corbet
Parent article: Cook: security things in Linux v5.0
It's not about fixing the people - they've already been fixed. When observing people carrying out a task, if they keep doing the same thing wrong, ask yourself why.
It's a pretty safe bet they're doing EXACTLY what they've been trained to do. It's just that the task they're doing is unusual, and their training is making them do the wrong thing.
Case in point - who was the idiot that decided that in Windows "tab" should step between fields, and "return" should send the completed form back to the program. It took a MAHOUSIVE training effort to fix that programming blunder, and people STILL get it wrong on a regular basis.
If people can't do it right, IT'S BECAUSE THEY'VE BEEN TRAINED TO DO IT WRONG, and you've got to *find* that training and fix it - which may not be possible.
(Another case in point - these latest 737 MAX crashes - the plane avionics have changed, and it seems pilots haven't been told that 20 or 30 years of training will make them instinctively do the wrong thing in a crisis ... - TRUE STORY!)
Cheers,
Wol
Python dictionary "addition" and "subtraction"
Posted Mar 14, 2019 15:41 UTC (Thu) by nybble41 (subscriber, #55106)In reply to: Python dictionary "addition" and "subtraction" by iabervon
Parent article: Python dictionary "addition" and "subtraction"
>>> { 'apple': 5, 'pear': 7 } + { 'strawberry': 2, 'pear': 10 }
{ 'apple': 5, 'pear': 17, 'strawberry': 2 }
>>> { 'x': 'abc', 'z': { 'a': 13 } } + { 'x': 'def', 'y': 'ijk', 'z': { 'a': 9, 'b': 10 } }
{ 'x': 'abcdef', 'y': 'ijk', 'z': { 'a': 22, 'b': 10 } }
This would make it similar to the Semigroup operator (<>) in Haskell.
Fixing programmers
Posted Mar 14, 2019 15:31 UTC (Thu) by nilsmeyer (guest, #122604)In reply to: Fixing programmers by farnz
Parent article: Cook: security things in Linux v5.0
Fixing programmers
Posted Mar 14, 2019 15:27 UTC (Thu) by HelloWorld (guest, #56129)In reply to: Fixing programmers by rweikusat2
Parent article: Cook: security things in Linux v5.0
Actually it does. "C with magic comment for fall-through" is a different (albeit similar) language than C, because the compiler actually enforces the comment. And empirically people are less likely to make the fall-through mistake in that language than they are in C.
5.1 Merge window part 1
Posted Mar 14, 2019 13:51 UTC (Thu) by nilsmeyer (guest, #122604)In reply to: 5.1 Merge window part 1 by anton
Parent article: 5.1 Merge window part 1
If that guarantee is broken you can of course demand your money back - you see where I'm going with this?
Fixing programmers
Posted Mar 14, 2019 13:45 UTC (Thu) by dottedmag (subscriber, #18590)In reply to: Fixing programmers by rweikusat2
Parent article: Cook: security things in Linux v5.0
GMP and assert()
Posted Mar 14, 2019 13:32 UTC (Thu) by mathstuf (subscriber, #69389)In reply to: GMP and assert() by jezuch
Parent article: GMP and assert()
git push
fatal error: no such file: path/to/some/lfs/file/on/another/branch
Note that this particular error is now better worded in that it mentions the object id that it is missing instead.
Fixing programmers
Posted Mar 14, 2019 12:16 UTC (Thu) by jem (subscriber, #24231)In reply to: Fixing programmers by Cyberax
Parent article: Cook: security things in Linux v5.0
I have learned that checklists are also being applied in surgery. The first item on the list is to check the patient's name.
Python dictionary "addition" and "subtraction"
Posted Mar 14, 2019 10:00 UTC (Thu) by sheepgoesbaaa (guest, #98005)In reply to: Python dictionary "addition" and "subtraction" by ms-tg
Parent article: Python dictionary "addition" and "subtraction"
Fixing programmers
Posted Mar 14, 2019 9:48 UTC (Thu) by dvdeug (guest, #10998)In reply to: Fixing programmers by rweikusat2
Parent article: Cook: security things in Linux v5.0
There's been other problems like this; Fortran require you to declare variables, so when programmers misspelled variable names, the compiler wouldn't warn the programmer. So those still using Fortran have the option of using "IMPLICIT NONE", not too dissimilar to C programmers having an option to have the compiler complain when they don't use a break or a note comment.
Fixing programmers
Posted Mar 14, 2019 9:30 UTC (Thu) by farnz (subscriber, #17727)In reply to: Fixing programmers by martinfick
Parent article: Cook: security things in Linux v5.0
Unfortunately, the mechanical mechanisms used for gas safety are based on the idea that you simply permit the flow of gas to run freely when the burner is warm enough; they just stop gas flow when cold, and use pressure on the control knob to open up the flow. The better ones use pressure on the control knob to start a release timer, after which you need to release the control knob and press it again to resume the flow of gas.
As with all safety mechanisms, they're not that hard to get around if you're determined - the point, however, is that a single mistaken decision on its own is not enough to cause a serious problem.
Python dictionary "addition" and "subtraction"
Posted Mar 14, 2019 9:27 UTC (Thu) by NRArnot (subscriber, #3033)Parent article: Python dictionary "addition" and "subtraction"
But if there is support, I'd argue strongly against using + and - operators. This is far more likely to lead to accidents than using |. This latter operator is far less frequently used, and seeing it always alerts one to the fact that something out of the ordinary is going on. Also one can visualize a set as a dict where all values are the same and irrelevant, such as True. In fact back before we had sets, that's what we used to do. So extending the set | operator to apply similarly to dicts makes reasonable sense.
Subtraction I like even less. Non-commutativity I can live with, but subtraction completely ignores the values in the dict being "Subtracted". A much better idea would be a dict.subtract( other) method.
GMP and assert()
Posted Mar 14, 2019 9:26 UTC (Thu) by jezuch (subscriber, #52988)In reply to: GMP and assert() by mathstuf
Parent article: GMP and assert()
Fixing programmers
Posted Mar 14, 2019 6:35 UTC (Thu) by adobriyan (subscriber, #30858)In reply to: Fixing programmers by Cyberax
Parent article: Cook: security things in Linux v5.0
Programming still have yet to grow up which is (slowly) happening.
Current situation is further complicated by very low barriers to entry.
Fixing programmers
Posted Mar 14, 2019 6:33 UTC (Thu) by epa (subscriber, #39769)In reply to: Fixing programmers by rweikusat2
Parent article: Cook: security things in Linux v5.0
A kernel unit-testing framework
Posted Mar 14, 2019 3:22 UTC (Thu) by Cyberax (✭ supporter ✭, #52523)In reply to: A kernel unit-testing framework by pbonzini
Parent article: A kernel unit-testing framework
A kernel unit-testing framework
Posted Mar 14, 2019 3:18 UTC (Thu) by jflombera (guest, #100225)Parent article: A kernel unit-testing framework
Fixing programmers
Posted Mar 14, 2019 3:14 UTC (Thu) by Cyberax (✭ supporter ✭, #52523)In reply to: Fixing programmers by martinfick
Parent article: Cook: security things in Linux v5.0
Turris: secure open-source routers
Posted Mar 14, 2019 3:05 UTC (Thu) by pabs (subscriber, #43278)In reply to: Turris: secure open-source routers by Cyberax
Parent article: Turris: secure open-source routers
https://osmocom.org/projects/quectel-modems/wiki
https://osmocom.org/news/63
http://git.gnumonks.org/laforge-slides/plain/2016/cellula...
https://media.ccc.de/v/33c3-8151-dissecting_modern_3g_4g_...
Fixing programmers
Posted Mar 14, 2019 2:00 UTC (Thu) by martinfick (subscriber, #4455)In reply to: Fixing programmers by farnz
Parent article: Cook: security things in Linux v5.0
Turris: secure open-source routers
Posted Mar 13, 2019 23:34 UTC (Wed) by Cyberax (✭ supporter ✭, #52523)Parent article: Turris: secure open-source routers
You do lose the ability to roll back using BTRFS snapshots and automatic upgrades though. Also some minor stuff (like nice rainbow LEDs) is not supported by the stock kernel.
Leaderless Debian
Posted Mar 13, 2019 23:01 UTC (Wed) by debacle (subscriber, #7114)In reply to: Leaderless Debian by mfuzzey
Parent article: Leaderless Debian
Fixing programmers
Posted Mar 13, 2019 22:25 UTC (Wed) by roc (subscriber, #30627)In reply to: Fixing programmers by rweikusat2
Parent article: Cook: security things in Linux v5.0
Personally I'd support people being free to chop off their own body parts if they insist on using unsafe equipment or unsafe programming languages, except that some of the costs inevitably fall on the community at large. For amputations, it's health care costs. For software, it's a combination of things: a software ecosystem polluted with vulnerable software, and a network ecosystem polluted with compromised devices.
The gas story is a good one.
Fixing programmers
Posted Mar 13, 2019 22:17 UTC (Wed) by farnz (subscriber, #17727)In reply to: Fixing programmers by rweikusat2
Parent article: Cook: security things in Linux v5.0
And yet both of those examples (bread slicers and kitchen gas) have been changed over the years to reduce the chances of not using them correctly, and to make sure that it takes continued incorrect operation in the face of a machine trying to stop you before you hurt yourself. Unlike C, you have to actively work to hurt yourself with modern designed appliances.
Modern bread slicers are designed such that you need the guard down over the bread to allow the slicing action to run; you can't have your fingers near the bread, but the guard holds the loaf in place when it's held in place. On high speed slicers, the guard is the trigger mechanism - you put the unsliced loaf in, push the guard down, loaf is sliced and machine pushes on the guard to tell you to release it and move onto the next loaf.
This compares to older slicers, where the blades are exposed, and there's no interlocking mechanism in place to stop you cutting your fingers - you put the loaf in, remove your hand, and push the trigger.
Similarly, with kitchen gas, older appliances would run the gas forever once you turned it on; modern appliances cut the gas the moment you let go of the controls unless the burner is hot, and will cut it if the burner cools off too far (implying flame lost). Further, they will stop the gas flow after a fixed time period if the burner remains cold, to reduce the chance of accidentally holding the control down without lighting the gas, and then blowing yourself up. It's thus very, very hard to actually get enough gas out of an appliance to trigger an explosion, even if you're trying to do it.
Python dictionary "addition" and "subtraction"
Posted Mar 13, 2019 22:11 UTC (Wed) by iabervon (subscriber, #722)In reply to: Python dictionary "addition" and "subtraction" by NYKevin
Parent article: Python dictionary "addition" and "subtraction"
I'd sort of guess that, if you've got an "or"-like thing, even if it doesn't short-circuit (i.e., evaluates all of its arguments), it'll pick between distinguishable values with the same truth value as if it were short-circuiting.
GMP and assert()
Posted Mar 13, 2019 22:05 UTC (Wed) by Wol (subscriber, #4433)In reply to: GMP and assert() by sorokin
Parent article: GMP and assert()
Dangerous statement :-) What about i?
Cheers,
Wol
Fixing programmers
Posted Mar 13, 2019 21:59 UTC (Wed) by Cyberax (✭ supporter ✭, #52523)In reply to: Fixing programmers by rweikusat2
Parent article: Cook: security things in Linux v5.0
In reality people make mistakes. A lot of time.
A good example here is surgery. A surgeon is a highly trained professional, you need almost a decade of intense training for it. In short, a surgeon is the first candidate for somebody who shouldn't make stupid mistakes.
Yet surgeons forgetting instruments inside patients was a common occurrence before a simple check was added - nurses count surgical instruments before and after the surgery.
Aviation? The same issue. Solved by checklists that HAVE to be followed.
Fixing programmers
Posted Mar 13, 2019 21:50 UTC (Wed) by rweikusat2 (subscriber, #117920)In reply to: Fixing programmers by roc
Parent article: Cook: security things in Linux v5.0
Just out of curiosity: Have you ever seen a bread slicing machine? Chances are that someone who doesn't get "using that" right every time will end up cutting off a part of his or her fingers. That's a seriously bloody and quite painful experience. Yet, people without a degree in anything are expected to be able to do that.
NB: This is still completely besides the point I was trying to make, it just illustrates that "misues of household devices is harmless !!! but misuse of switch Catastrophical !!1" is an nonsensical assertion despite misuse happend to be harmless for an example I used because it served as illustration for something completely different.
Random story I feel like telling here: A couple of years ago, I read about a guy who was resolved to commit suicide and thus, turned the gas on in his kitchen. After waiting for terminal results for a while, he suddenly changed his mind, turned the gas off again and opened the kitchen window. To celebrate his decision to face this life somewhat more, he then lighted a cigarette. The roof of the house was blown of but he survived with serious burns and was later sentenced for arson.
Fixing programmers
Posted Mar 13, 2019 21:38 UTC (Wed) by rweikusat2 (subscriber, #117920)In reply to: Fixing programmers by rahulsundaram
Parent article: Cook: security things in Linux v5.0
/* fallthru */
to express that they were actually planning to use a certain language feature in a machine-readable way is seriously old. The effect of this is that features someone considers particularly disagreeable become somewhat more complicated to use and that the code becomes cluttered (to a degree) with completely useless comments. Presence or absence of such comments doesn't indicate anything about correctness or incorrectness of the code.
Python dictionary "addition" and "subtraction"
Posted Mar 13, 2019 21:35 UTC (Wed) by NYKevin (subscriber, #129325)In reply to: Python dictionary "addition" and "subtraction" by iabervon
Parent article: Python dictionary "addition" and "subtraction"
1. Single pipe is traditionally commutative (bitwise OR, set union, etc.). It has been used non-commutatively (shell pipelines), but that usage is so far afield that it provides no intuition here.
2. Double pipe (or the "or" keyword) traditionally short-circuits to the left. I've never seen it short-circuit to the right.
3. Plus is sometimes commutative, but its noncommutative uses traditionally preserve the order of items (concatenation) rather than allowing one item to "override" another. So the closest analogue here would be c = ChainMap(a, b) (so that you have c.maps == [a, b]) as Hettinger suggests... but that actually gives precedence to the left! ChainMap.new_child() does give precedence to the "right" in a sense, but it's type-asymmetric (self is a ChainMap, the argument usually isn't), and probably should not be an operator at all.
Fixing programmers
Posted Mar 13, 2019 21:12 UTC (Wed) by roc (subscriber, #30627)In reply to: Fixing programmers by rweikusat2
Parent article: Cook: security things in Linux v5.0
I don't expect people to put the right key in the right lock first try every single time, just like I don't expect C developers to always remember to put "break" after switch cases. But because the consequences of the former are "it didn't work, try again" (i.e. negligible), it *is* reasonable to expect unskilled people to successfully enter their flat. The goal of the changes reported here, which you apparently oppose, is to change the consequences of omitting a "break" to something similar (whereas currently the consequences can be much more severe and fall on other parties).
TMTOWTDI
Posted Mar 13, 2019 20:53 UTC (Wed) by jccleaver (guest, #127418)Parent article: Python dictionary "addition" and "subtraction"
> %hash2 = (%hash1, %hash2); # %hash2 values will take priority
There are other ways to handle it if you need to watch memory usage in pathological cases, but sometimes simple things should be simple.
Fixing programmers
Posted Mar 13, 2019 20:45 UTC (Wed) by rahulsundaram (subscriber, #21946)In reply to: Fixing programmers by rweikusat2
Parent article: Cook: security things in Linux v5.0
Lots of tooling existed before but being part of the compiler makes them more readily available and even better if it is the default.
Fixing programmers
Posted Mar 13, 2019 20:38 UTC (Wed) by rweikusat2 (subscriber, #117920)In reply to: Fixing programmers by rahulsundaram
Parent article: Cook: security things in Linux v5.0
Fixing programmers
Posted Mar 13, 2019 20:35 UTC (Wed) by rweikusat2 (subscriber, #117920)In reply to: Fixing programmers by roc
Parent article: Cook: security things in Linux v5.0
That I happened to use an example to illustrate something specific (complicatedness of a procedure) doesn't mean any side properties of said example are relevant to the discussion because they exist (or are believed to exist).
Fixing programmers
Posted Mar 13, 2019 20:27 UTC (Wed) by roc (subscriber, #30627)In reply to: Fixing programmers by rweikusat2
Parent article: Cook: security things in Linux v5.0
Absent the kind of work described here that you are objecting to, omitting a "break" is not immediately detected and can have lasting consequences up to and including users you don't even know having their systems compromised by hostile forces.
It would be a better analogy if every time you touched a lock with the wrong key you got an electric shock. It would be interesting to see how long you tolerated that situation because "human beings without any qualifications should be able to do this".
Fixing programmers
Posted Mar 13, 2019 19:43 UTC (Wed) by rahulsundaram (subscriber, #21946)In reply to: Fixing programmers by rweikusat2
Parent article: Cook: security things in Linux v5.0
All the empirical evidence including plenty of research and billions of dollars spent on fixing bugs in such code clearly indicates otherwise.
> And adding /** I really disagree **/ comments to source code doesn't improve that (the code).
That's not really what is happening here though. The specific comment here is being parsed by the compiler and therefore really is part of the code.
Fixing programmers
Posted Mar 13, 2019 19:40 UTC (Wed) by Cyberax (✭ supporter ✭, #52523)In reply to: Fixing programmers by rweikusat2
Parent article: Cook: security things in Linux v5.0
The number of CVEs caused by a missed "break" tends to confirm that people suck at math.
Fixing programmers
Posted Mar 13, 2019 19:35 UTC (Wed) by rweikusat2 (subscriber, #117920)In reply to: Fixing programmers by corbet
Parent article: Cook: security things in Linux v5.0
The C switch statements has certain properties. One could argue whether all of these properties are really desirable, but that's not going to change it. And adding /** I really disagree **/ comments to source code doesn't improve that (the code).
I have to open three different locks with three different keys when trying to get into my flat. Two of them even look identical and can only be distinguished by knowing their relative positions on the keyring. This is vastly more complicated than remembering that a break needs to be added to the end of 'a switch case 'if execution of code in the corresponding block is supposed to be terminated. Yet, human beings without any higher qualifications are expected to be able to do the former while it is claimed that "nobody" can do the latter. Strange, isn't it?
Whenever people have to make a decision, they'll sometimes get this decision wrong. But they will usually get it right most of the time, as evidenced by the miniscule number of missing breaks (compared to the size of the codebase) found during the course of this (a Linux source I happen to have lying around here contains 45,021 switch statements. 20 missing breaks in n * 45,021 cases, n > 2, is decidedly miniscule).
Python dictionary "addition" and "subtraction"
Posted Mar 13, 2019 19:26 UTC (Wed) by ms-tg (subscriber, #89231)In reply to: Python dictionary "addition" and "subtraction" by smurf
Parent article: Python dictionary "addition" and "subtraction"
Definitely!
In fact, Ruby provides a way to do it *without monkey-patching* called Refinements:
https://ruby-doc.org/core-2.5.3/doc/syntax/refinements_rd...
So if you wanted to extend the Ruby Hash class (equivalent to Python Dict) in this way with method #+ and #+=, you could create the following refinement module:
module HashWithPlus
refine Hash do
alias_method :+, :merge
alias_method :"+=", :merge!
end
end
Then, in any lexical scope you can say:
using HashWithPlus
{ "a" => 1 } + { "b" => 2}
=> {"a"=>1, "b"=>2}
With no monkey-patching! The refined Hash will only be visible in scopes that explicitly use the refinement.
(just sharing for those interested)
The Thunderclap vulnerabilities
Posted Mar 13, 2019 19:17 UTC (Wed) by rweikusat2 (subscriber, #117920)In reply to: The Thunderclap vulnerabilities by nybble41
Parent article: The Thunderclap vulnerabilities
> The page cache would need to be separate for each *device*, not each driver.
A driver capable of managing more than one device would obviously need one cache per currently managed device. Do you think somebody wouldn't immediately recognize this if such a driver was under discussion?
Fixing programmers
Posted Mar 13, 2019 19:15 UTC (Wed) by corbet (editor, #1)In reply to: Cook: security things in Linux v5.0 by rweikusat2
Parent article: Cook: security things in Linux v5.0
Perhaps because humans have this nasty tendency to be ... humans ... who will, when using a language that makes it easy to code certain types of mistakes, make those mistakes? Fixing the people has never been a workable solution to this kind of security issue; why would you expect this case to be different?
Python dictionary "addition" and "subtraction"
Posted Mar 13, 2019 19:14 UTC (Wed) by iabervon (subscriber, #722)Parent article: Python dictionary "addition" and "subtraction"
Cook: security things in Linux v5.0
Posted Mar 13, 2019 19:12 UTC (Wed) by rweikusat2 (subscriber, #117920)Parent article: Cook: security things in Linux v5.0
What about "fixing" people writing code in C (the language is not that complicated, mind you) instead of inventing one bazillion
/*** OMFG !! Not like Pascal !!! ***/ pseudosyntactic tags?
Cook: security things in Linux v5.0
Posted Mar 13, 2019 18:38 UTC (Wed) by zblaxell (subscriber, #26385)Parent article: Cook: security things in Linux v5.0
"-Werror=implicit-fallthrough" would be more effective, but you'd have to get all the way to zero warnings first.
5.1 Merge window part 1
Posted Mar 13, 2019 18:16 UTC (Wed) by anton (subscriber, #25547)In reply to: 5.1 Merge window part 1 by willy
Parent article: 5.1 Merge window part 1
Unfortunately, I do not have the time to pursue such a project. I can provide binaries and libraries for testing, if someone wants to do it, though.
As for the security excuse: 1) You don't even have any proof of such a vulnerability; is your belief enough justification to break existing code? 2) Even if there was such a vulnerability, the attacker would have to break into my system first before exploiting it. 3) Those who are nervous about such a hypothetical vulnerability can disable the module.
The Linux Foundation's CommunityBridge platform
Posted Mar 13, 2019 17:36 UTC (Wed) by karkhaz (subscriber, #99844)Parent article: The Linux Foundation's CommunityBridge platform
> supports the “BDFL” FOSS governance model, which has already been widely discredited
u wot mate?
Python dictionary "addition" and "subtraction"
Posted Mar 13, 2019 17:17 UTC (Wed) by smurf (subscriber, #17840)In reply to: Python dictionary "addition" and "subtraction" by pj
Parent article: Python dictionary "addition" and "subtraction"
Python dictionary "addition" and "subtraction"
Posted Mar 13, 2019 16:52 UTC (Wed) by pj (subscriber, #4506)Parent article: Python dictionary "addition" and "subtraction"
NO TO SYSVINIT - or initscripts, rather!
Posted Mar 13, 2019 16:30 UTC (Wed) by nopsled (guest, #129072)In reply to: NO TO SYSVINIT - or initscripts, rather! by luto
Parent article: Init system support in Debian
It would be nice if Linux had the PROC_REAP_KILL stuff. I think one could improve the FreeBSD interface a tad bit when incorporating it, but the concept looks sound.
systemd ofcourse has one supervisor per context (system or user), but this will be especially useful for supervisors that have one monitor per service (s6, runit style), and that these can be nested supervisors (so an option to not cross subreaper boundaries where each supervisor is a subreaper, or a way to kill inherited children only, and a way to kill direct children only, and OR the flags to do both). You could get creative, but if done right, this could solve a lot of woes with process management.
The Linux Foundation's CommunityBridge platform
Posted Mar 13, 2019 16:29 UTC (Wed) by keithp (subscriber, #5140)Parent article: The Linux Foundation's CommunityBridge platform
"This new LF system is probably just right for FOSS projects that (a) prefer to use single-point-of-failure, proprietary software rather than FOSS for their infrastructure, (b) do not want to operate in a way that is dedicated to the public good, and (c) have very minimal fiscal sponsorship needs, such as occasional reimbursements of project expenses."
Just another LF attempt to look like a part of our community and failing?
The Thunderclap vulnerabilities
Posted Mar 13, 2019 15:21 UTC (Wed) by nybble41 (subscriber, #55106)In reply to: The Thunderclap vulnerabilities by rweikusat2
Parent article: The Thunderclap vulnerabilities
The page cache would need to be separate for each *device*, not each driver. A device snooping on itself may be harmless, but the same is not necessarily true for snooping on other devices managed by the same driver. Besides the fact that one driver might manage multiple brands and models of devices, some more trustworthy than others, one can also envision e.g. a system with two identical NICs surreptitiously snooping on each other and transmitting internal network data over the external network.
An "i3" is also a window manager.
Posted Mar 13, 2019 4:54 UTC (Wed) by codyharrington (guest, #130219)In reply to: An "i3" is also a window manager. by gmatht
Parent article: Announcing the release of sway 1.0
"i3 is a tiling window manager designed for X11, inspired by wmii, and written in C."
Regarding Sway, from their website:
"Sway is a tiling Wayland compositor and a drop-in replacement for the i3 window manager for X11. It works with your existing i3 configuration and supports most of i3's features, plus a few extras.".
Malcolm: Usability improvements in GCC 9
Posted Mar 12, 2019 23:44 UTC (Tue) by simlo (guest, #10866)In reply to: Malcolm: Usability improvements in GCC 9 by rweikusat2
Parent article: Malcolm: Usability improvements in GCC 9
I am software architect on a product containing Java, C, C++ and a few scripting things around as well. The code with fewest bugs is the C++ - even though we make far the most complicated algorithms in C++.
Some of the previous (lead) developers bought that code close to the hardware has to be C. That code is terrible and impossible to unit test. We recently had to spend a lot of hours patching for a simple memory leak, which simply wouldn't have happened with modern C++ code style (smart pointers).
The Java code is a lot better than the C, but there are way too many treads.
I agree with one huge problem in C++, though: It doesn't scale to large project, since each project around choose their own subset of the language and conventions. When you try merge the projects in one binary it falls apart. Java is much better in that sense.
The Thunderclap vulnerabilities
Posted Mar 12, 2019 21:50 UTC (Tue) by rweikusat2 (subscriber, #117920)In reply to: The Thunderclap vulnerabilities by westeri
Parent article: The Thunderclap vulnerabilities
Yes. I thought I already wrote this ("this should really be all kinds of devices"): If this issue is supposed to be mitigated by the IOMMU, any driver which supports DMA would need to use its own DMA buffer backing pages cache. There's no need for individual buffers to span a complete page (or some number of complete pages) provided management information used by a driver isn't kept in the unused parts of some page a part of which is currently used as DMA buffer, at least not in a way where corruption could go unnoticed. Malicious device snooping on itself sounds pretty harmless to me ;-).
Assuming that fixing this is considered desirable (the underlying issue has existed forever --- there's no reason why hardware designed by an unknown entity ought to be trustworthy, especially not if this 'hardware' is in itself complicated enough to contain a general purpose CPU running some decidedly non-trivial software), this cries out for some sort of infrastructure support for DMA buffer allocation drivers could easily make use of.
NB: I understand the benefits of the existing approach. But that's still just life-patching of a more fundamentally deficient (in this respect) memory management model.
The Thunderclap vulnerabilities
Posted Mar 12, 2019 21:01 UTC (Tue) by westeri (subscriber, #62678)In reply to: The Thunderclap vulnerabilities by rweikusat2
Parent article: The Thunderclap vulnerabilities
The Thunderclap vulnerabilities
Posted Mar 12, 2019 19:48 UTC (Tue) by rweikusat2 (subscriber, #117920)In reply to: The Thunderclap vulnerabilities by westeri
Parent article: The Thunderclap vulnerabilities
Assuming that memory protection/ accesss control with page granularity is available, DMA buffers used by untrusted devices (and this should really be all kinds of devices) must not share memory pages with code whose information said untrusted devices are not supposed to access if the access control is supposed to be used effectively. This means *if* such a facility is to be used in a sensible way, DMA buffer allocation must be per-device and separate from all other allocations, including other DMA buffer allocation.
There are obviously tradeoffs here as most real-world devices won't be untrusted but singling out a certain kind of devices and adding an additional DMA buffer allocation system working on top of the existing DMA buffer allocation systems is a technically seriously unpleasant workaround for a highly unlikely fringe case.
The Thunderclap vulnerabilities
Posted Mar 12, 2019 17:18 UTC (Tue) by k8to (guest, #15413)In reply to: The Thunderclap vulnerabilities by flussence
Parent article: The Thunderclap vulnerabilities
Which is probably what you were getting at.
Malcolm: Usability improvements in GCC 9
Posted Mar 12, 2019 17:10 UTC (Tue) by k8to (guest, #15413)In reply to: Malcolm: Usability improvements in GCC 9 by tdz
Parent article: Malcolm: Usability improvements in GCC 9
5.1 Merge window part 1
Posted Mar 12, 2019 16:35 UTC (Tue) by willy (subscriber, #9762)In reply to: 5.1 Merge window part 1 by anton
Parent article: 5.1 Merge window part 1
Continuing to support the a.out format has risks. The initial proposal to remove the a.out coredump support was due to bugs being found in it. Given the amount of testing the a.out code receives as a whole, I have little doubt that a determined attacker could find a security hole to exploit in it.
Since you appear to be a programmer yourself, how would you like to take up Alan Cox's suggestion of writing an a.out loader entirely in userspace?
The Thunderclap vulnerabilities
Posted Mar 12, 2019 16:16 UTC (Tue) by westeri (subscriber, #62678)In reply to: The Thunderclap vulnerabilities by rweikusat2
Parent article: The Thunderclap vulnerabilities
Leaderless Debian
Posted Mar 12, 2019 14:58 UTC (Tue) by liw (subscriber, #6379)In reply to: Leaderless Debian by lamby
Parent article: Leaderless Debian
5.1 Merge window part 1
Posted Mar 12, 2019 14:34 UTC (Tue) by anton (subscriber, #25547)Parent article: 5.1 Merge window part 1
Support for the ancient a.out executable format has been deprecated, with an eye toward removing it entirely later this year if nobody objects.Where do I register my objections?
Just today I found that my system can run my good old QMAGIC binaries with a little help from me (I have yet to find out how to do it as non-root, and how to run ZMAGIC binaries). I use this to compare the old stuff to the new one, both in features and in performance, and want to continue to do so in the next decades.
Couldn't the same be achieved by always recompiling from the source? No, for several reasons: 1) One of the things I compare is what the compiler produced. 2) Unlike the Linux kernel maintainers, compiler maintainers usually do not give a guarantee not to break existing code, and consequently, the chances of 20+-year old source code compiling on a current compiler are not that great.
Interestingly, my recent investigation of a.out binaries was in reaction to a posting containing the claim:
So, [Windows has] a window of ~ 25 years where binaries still typically work, vs Linux being "maybe a few years, and only on a single distro".Do the Linux kernel maintainers want to prove that poster right? And that despite giving the guarantee not to break existing code? Of course, binary compatibility problems are not just a kernel issue, but kernel maintainers should do their part in maintaining binary compatibility (as should others).
The Thunderclap vulnerabilities
Posted Mar 12, 2019 14:25 UTC (Tue) by rweikusat2 (subscriber, #117920)In reply to: The Thunderclap vulnerabilities by westeri
Parent article: The Thunderclap vulnerabilities
An "i3" is also a window manager.
Posted Mar 12, 2019 13:22 UTC (Tue) by mathstuf (subscriber, #69389)In reply to: An "i3" is also a window manager. by gmatht
Parent article: Announcing the release of sway 1.0
Specifically, the configuration file (mainly bindings, workspace settings, etc.). I assume there are new variables in sway for the bits that Wayland expects compositors to provide over X's requests of window managers.
The Thunderclap vulnerabilities
Posted Mar 12, 2019 11:02 UTC (Tue) by westeri (subscriber, #62678)In reply to: The Thunderclap vulnerabilities by rweikusat2
Parent article: The Thunderclap vulnerabilities
https://lore.kernel.org/lkml/20190312060005.12189-1-baolu...
An "i3" is also a window manager.
Posted Mar 12, 2019 11:00 UTC (Tue) by mips (guest, #105013)In reply to: An "i3" is also a window manager. by gmatht
Parent article: Announcing the release of sway 1.0
I can find no statement on whether this is supported by sway.
Leaderless Debian
Posted Mar 12, 2019 9:44 UTC (Tue) by lamby (subscriber, #42621)Parent article: Leaderless Debian
This has now been made explicit: https://lists.debian.org/debian-vote/2019/03/msg00014.html
Leaderless Debian
Posted Mar 12, 2019 9:22 UTC (Tue) by ulysse68 (guest, #35632)In reply to: Leaderless Debian by Cyberax
Parent article: Leaderless Debian
Malcolm: Usability improvements in GCC 9
Posted Mar 12, 2019 9:21 UTC (Tue) by tdz (subscriber, #58733)In reply to: Malcolm: Usability improvements in GCC 9 by rweikusat2
Parent article: Malcolm: Usability improvements in GCC 9
Leaderless Debian
Posted Mar 12, 2019 9:12 UTC (Tue) by Karellen (subscriber, #67644)Parent article: Leaderless Debian
@mjg - as bdale suggested at the end of your talk, are you sure you can't be convinced to run on your "heresies" platform? ;-)
Leaderless Debian
Posted Mar 12, 2019 8:58 UTC (Tue) by andrewsh (subscriber, #71043)In reply to: Leaderless Debian by Cyberax
Parent article: Leaderless Debian
Leaderless Debian
Posted Mar 12, 2019 8:53 UTC (Tue) by cevin666 (guest, #960)In reply to: Leaderless Debian by edomaur
Parent article: Leaderless Debian
Leaderless Debian
Posted Mar 12, 2019 8:14 UTC (Tue) by Cyberax (✭ supporter ✭, #52523)Parent article: Leaderless Debian
Leaderless Debian
Posted Mar 12, 2019 7:49 UTC (Tue) by mfuzzey (subscriber, #57966)Parent article: Leaderless Debian
An "i3" is also a window manager.
Posted Mar 12, 2019 7:18 UTC (Tue) by bangert (subscriber, #28342)In reply to: An "i3" is also a window manager. by gmatht
Parent article: Announcing the release of sway 1.0
Leaderless Debian
Posted Mar 12, 2019 5:05 UTC (Tue) by edomaur (subscriber, #14520)Parent article: Leaderless Debian
Woof !
An "i3" is also a window manager.
Posted Mar 12, 2019 2:13 UTC (Tue) by gmatht (subscriber, #58961)Parent article: Announcing the release of sway 1.0
For people who are as confused as I was, there is also a lesser known "i3" which is a form of window manger. I presume sway is compatible with the i3 window manager (in addition to Intel i3).
The Thunderclap vulnerabilities
Posted Mar 11, 2019 19:50 UTC (Mon) by rweikusat2 (subscriber, #117920)In reply to: The Thunderclap vulnerabilities by nix
Parent article: The Thunderclap vulnerabilities
Linux has a general purpose kernel memory allocator. This is a power-of-2-freelist allocator sitting atop the page allocator (more precisely it's implemented as set of object caches for objects whose sizes are powers-of-two). As detailed in the paper, the e1000 driver allocates skbs via kmalloc. This means its network buffers will usually occupy some part of a page. An access control mechanism with page granularity thus cannot prevent malicious devices from accessing the remaining part of the page. As that's just one of the pages currently allocated to one of the kmalloc caches, any other part of the kernel which uses kmalloc could end up using this "remaining part of the page".
The gist of this is that a (page-based) IOMMU can only prevent malicious devices from accessing data they're aren't supposed to access if the devices drivers used for such devices do their own memory management based getting complete pages from the page allocator.
Malcolm: Usability improvements in GCC 9
Posted Mar 11, 2019 19:45 UTC (Mon) by xtifr (guest, #143)In reply to: Malcolm: Usability improvements in GCC 9 by NYKevin
Parent article: Malcolm: Usability improvements in GCC 9
It's a much *larger* ad-hoc informally specified bug-ridden slow implementation of half of Common Lisp. :) C++11, in particular, adds lambdas to the language, for extra bonus lispiness. :)
(I was actually about ready to give up on C++ until C++11, which returned to the list of languages I don't mind *too* terribly.)
Introducing Season of Docs
Posted Mar 11, 2019 18:13 UTC (Mon) by Zenith (guest, #24899)Parent article: Introducing Season of Docs
Kudos to Google for this!
Malcolm: Usability improvements in GCC 9
Posted Mar 11, 2019 18:08 UTC (Mon) by rweikusat2 (subscriber, #117920)In reply to: Malcolm: Usability improvements in GCC 9 by tdz
Parent article: Malcolm: Usability improvements in GCC 9
There are no "data structures" in C standards, there's just a convention for representing strings.
