Remove text in redacted files when exporting to PDF

As you may or may not now, some of the Epstein files got released as PDF and where exported from a text editor to PDF. The US government apparently redacted the files by just using a black highlight filler on the text. This does only make the text unreadable in the PDF, but the text is still there.
Example: 2022.03.17-1 Exhibit 1.pdf

Speaking from the technical side: The background highlight just places a coloured box over the text in the PDF while leaving the text in place.

I wondered if there is any way on LibreOffice to create a PDF where such redacting really removes the text on export, yet leaves the rest of the text intact.
A solution should be as user friendly as using the black highlight marker on text.

EDIT: It may is possible to tell Writer to not print certain characters, but the text should stay in place and not break the text layout

I don’t think you followed the instructions for redacted text in pdfs.
When the document opens in Draw, it also opens the redaction toolbar. You must use the redaction toolbar to export the document as pdf otherwise it doesn’t work as expected

Well, I didn’t follow it because I didn’t know this even existed (this is why it was an open question from my side). As I never questioned how redaction is done, I further had no clue what really to search for and just used the words from the news videos I saw about this.

However, this is not really what I meant.
Following the instructions on the help page, it seems

  1. I can’t do the task within writer itself (I need Draw)
  2. The PDF is exported as image and not as searchable text. This would mean you need an OCR tool ran across it (with it’s own chance of error) before it can be used. (My case study are the Epstein files and how I would create them in LibreOffice. Being searchable is IIRC required, thus meaning an image of the text is not enough)
  3. Using the lorem ipsum text (“LOREM” + F3) to test this feature, it produces a very bad visual quality test with lots of noise that seem to come from compression (I didn’t see any option to improve the quality in the redaction toolbar)

The problem for me is that this seems very labour intensive and is only really good for small documents. There seems to be no option eg. in Writer to mark several rows, click on one button and flag the entire marked area as text being redacted on export.

…and Draw comes bundled in LibreOffice, its functions are integral to LibreOffice.

Except as demonstrated in the film Hidden Figures where the text could be read through the paper held up to the light.

That is how it works in Draw, there is also a freehand option

Did you read the linked help Automatic Redaction ?

If you wanted to do it manually, you could use Find and Replace to replace words and phrases with an equivalent number of spaces or black square characters, ■, with or without black highlighting and then export to pdf normally

[Edit]
Following another, unrelated recent question you could try Stirling, shown in 6 open-source PDF editors I prefer over Acrobat for better document management . Apparently, Redact is one of the tools included in the free package.