HN user

amboar

577 karma
Posts29
Comments112
View on HN
lists.linuxfoundation.org 9y ago

Inhibiting a covert attack on the Bitcoin POW function

amboar
3pts0
www.smh.com.au 9y ago

Australian Census 2016: Error messages abound

amboar
12pts2
subt0x10.blogspot.com 10y ago

Regsvr32.exe: Bypass Application Whitelisting Script Protections

amboar
5pts0
www.acsc.gov.au 10y ago

Australian Cyber Security Centre 2015 Threat Report [pdf]

amboar
1pts0
lambda-the-ultimate.org 10y ago

Reagents: Expressing and Composing Fine-Grained Concurrency

amboar
46pts0
blog.regehr.org 12y ago

ALIVe: Automatic LLVM InstCombine Verifier

amboar
1pts0
www.windytan.com 12y ago

Time-coding audio files

amboar
3pts0
rusty.ozlabs.org 12y ago

Effects of packet/data sizes on various networks

amboar
1pts0
programmingisterrible.com 12y ago

How I fail to design software

amboar
1pts0
cdn.preterhuman.net 12y ago

Murphys Law and those of similar ilk

amboar
1pts0
vanillajava.blogspot.com.au 12y ago

Java arrays, Wat?

amboar
1pts0
blog.flameeyes.eu 12y ago

NFC, Credit Cards and exposed data

amboar
1pts1
www.advogato.org 12y ago

Real-world Secure Boot attacks

amboar
2pts0
semiaccurate.com 12y ago

ARM bases Compiler 6 on Clang/LLVM

amboar
5pts0
rusty.ozlabs.org 12y ago

Legal Questions About LocalBitcoins.com and Australia

amboar
2pts0
groups.google.com 12y ago

Gerrit v2.8.3: Fixes serious bugs in merge strategies

amboar
1pts0
www.devttys0.com 12y ago

Cracking Linksys “Encryption”

amboar
132pts46
blog.regehr.org 12y ago

Embedded in Academia: Let’s Work on an LLVM Superoptimizer

amboar
5pts0
blog.jooq.org 12y ago

On Java 8′s introduction of Optional

amboar
1pts0
vanillajava.blogspot.com.au 12y ago

Hardware Transactional Memory in Java

amboar
2pts0
benno.id.au 12y ago

Inversion of Meaning

amboar
3pts0
wdtz.org 12y ago

Catching pointer overflow bugs

amboar
2pts0
arstechnica.com 12y ago

A primer on elliptic curve cryptography

amboar
53pts15
lwn.net 12y ago

The 2013 Kernel Summit

amboar
2pts0
opensource.com 12y ago

Seven reasons why closed source is better than open source

amboar
2pts2
ccodearchive.net 12y ago

CCAN: The C Code Archive

amboar
4pts0
blog.llvm.org 12y ago

A path forward for an LLVM toolchain on Windows

amboar
10pts1
lwn.net 13y ago

On kernel mailing list behavior

amboar
2pts0
www.theregister.co.uk 13y ago

Oracle knew about critical Java flaws since April

amboar
179pts88

I've become pretty enthusiastic about checklists.

In case it helps anyone else, I wrote a small tool that helps maintain and execute them:

https://github.com/amboar/checklists/

It's just a shell script wrapped around $EDITOR and git. The intent is to write checklists in the style of github-flavoured markdown. It has some tricks such as envsubst(1) interpolation and embedding little scripts whose execution is captured alongside the execution itself.

Here's an example checklist that's fairly well-worn (though is somewhat dated):

https://gist.githubusercontent.com/amboar/f85449aad09ba22219...

Where checklist entries are commands I just copy/paste them into a shell session. Usually this is in a tmux split with the checklist on one side with a shell on the other.

Could more of it be automated? Perhaps, though when some of the steps fail for various reasons, I find it's easier to recover or repair the situation if I have been invoking them myself sequentially. The embedded script support enables progressive automation where stability of the results is demonstrated over time.

As I haven't seen a link to it in the comments yet: A while back Hillel Wayne put some effort into resolving the question of "Is Software Engineering Real Engineering?" with the crossover project: https://www.hillelwayne.com/talks/crossover-project/

The conclusion he drew was that there's less difference than you might expect between software development and "traditional" engineering disciplines and that it's reasonable to consider software engineering a real engineering discipline.

GCC 15.1 1 year ago

Section J.1 _Unspecified_ behavior says

(11) The values of bytes that correspond to union members other than the one last stored into (6.2.6.1).

So it's a little more constrained in the ramifications, but the outcomes may still be surprising. It's a bit unfortunate that "UB" aliases to both "Undefined behavior" and "Unspecified behavior" given they have subtly different definitions.

From section 4 we have:

A program that is correct in all other aspects, operating on correct data, containing unspecified behavior shall be a correct program and act in accordance with 5.1.2.4.

Yeah, I have rerere turned on However, it's not directly beneficial for the process outlined. With what I wrote about you only solve a given conflict at the end of a complete bisect run, not at each bisection point inside a run. The bisect/cherry-pick process is only used to determine whether conflicts do or don't happen at a given upstream commit. Usually you will solve a specific conflict only once, regardless of whether rerere is enabled.

It was eating characters, which is the second worst thing it could do.

Okay, that's interesting. Did you file a bug with your system's firmware provider or with upstream?

You can file it against obmc-console at https://github.com/openbmc/obmc-console/issues

Digging into the source, I found a really wonky software buffer... which kind of blew my mind - since hardware buffers and flow control exist.

Yep, it's how OpenBMC provides the console via IPMI, Redfish, SSH and on the commandline, as well as routing the console out to the connector on the rear of the chassis.

I don't remember if that was a case where python was somehow in the pipeline, but that was unfortunately very common in OpenBMC.

Generally there hasn't been any python in the console handling pipeline. That said, python, while especially slow on a BMC, was pretty important for getting the project off the ground.

At this point OpenBMC has been python-free for several years.

I also had a lot of trouble getting the thing to honor the most basic settings, like baud rate

There's some nuance to this, as depending on your system design the console may be coming from the host to the BMC via Aspeed's Virtual UARTs (VUARTs). The way the VUARTs work is the BMC and host are connected to either end of the two FIFOs between the UARTs' APB and LPC/eSPI interfaces. As such there's no baud rate as no data is clocked out in RS-232 fashion - the data is transferred as quickly as either side can access their register interfaces.

This has caused issues in the past with control flow that lead to data integrity issues:

https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/lin...

https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/lin...

But it is harder to confidently place the blame on that one. Is it OpenBMC's fault that the software provides no clue as to where things are going wrong in the serial plumbing? Is it the AST2500's fault that designers are routing every serial line through it and making it impossible to eliminate as the cause while troubleshooting?

I agree it can be difficult to debug where things are going wrong in the console pipeline.

In concept a serial console should be simple, but when you bring in requirements like various kinds of SoL, it starts to get more complex.

- braindamaged linking

I mean, it's simple, but brain-damaged?

- "if (!pred(x) || a <= b && y)" for "if not pred(x) or a =< b and y"

I guess more parentheses would improve the clarity but your English translation suffers the same problem as the code

the c pre-processor

- a broken comment syntax (how do you comment out a region with comments inside?)

Use the pre-processor that you complained about

#if 0 ... #endif

Use a packed struct (e.g. __attribute__((packed))). You may take a performance hit due to lack of alignment, but that's the judgement call

Right; then it comes down to platform design and whether you can reboot the soc in a mode that both reopens the bridges and doesn't kill the host, though that's not relevant if you're accessing it from the UART debug interface.

FWIW the mitigation patch in OpenBMC turns off all the bridges early in u-boot to minimise the race window for system reset/AC cycles.

Obviously would be better if it was possible to avoid the race window entirely (i.e. bridges default to closed, can be strapped open by the platform designer, and opened as required by firmware). We had asked for hardware changes along these lines for future generations (but may need to push a little harder...)

The description looks bad on the surface, but as always reality is more nuanced. These issues are only problematic in specific circumstances, particularly, bare-metal cloud hosting where the BMC might be in a separate trust domain to the host and the user on the host is provided with root (or equivalent) privileges. If your threat model is "root on the host owns the platform" then the only problem is that the BMC is yet another spot to hide malware.

The concern is that existing BMC firmwares have been shown as unsafe for bare-metal cloud types of configurations by default, so organisations using platforms in this environment may be doing so with false confidence.

The BMC (IPMI) is also a self sufficient ARM computer

ASPEED BMC SoCs (popular BMC SoCs also used in OpenPOWER systems) have a ColdFire (m68k) co-processor buried inside them. In OpenPOWER OpenBMC firmwares we use the ColdFire to bitbang a JTAG-ish protocol into the POWER chip