1

I can't Print the page or copy the text because it is for some reason encrypted downloading is not an option!

If I copy the following:

She is unapproachable

I get this when pasted in any program/app:

Zdn az ~gfppbfjdf`hn

The online PDF.

Similar questions like, Can't copy text from a pdf file do not fit in the description of my question, and I have been searching for 1 hour now.

Could anyone point me in the right direction?

Rafael
  • 115
  • 1
  • 6

1 Answers1

4

I don't have a solution for the question you're actually asking, that is, how to copy text and have it come out readable.

However! It looks from your example like the "encryption" here is a simple character substitution. This being the case, it wouldn't be too hard to pass the copied text through a filter to decrypt it and produce a readable result. For example, assume the following script called decrypt.pl:

#!/usr/bin/perl
use strict;

use utf8;
binmode STDIN, ':utf8';

my %map = (
           # from => to
           'z' => 's',
           'd' => 'h',
           'n' => 'e',
           'a' => 'i',
           '~' => 'u',
           'g' => 'n',
           'f' => 'a',
           'p' => 'p',
           '' => 'r',
           'b' => 'o',
           'j' => 'c',
           'd' => 'h',
           '`' => 'b',
           'h' => 'l',
           # other substitutions here
          );

while (my $line = <STDIN>) {
  foreach my $char (split(//, $line)) {
    my $upcase = (lc($char) eq $char ? 0 : 1);
    my $found = $map{lc($char)};
    if (!$found) {
      die "No substitution found for character '$char'\n";
    };
    $found = uc($found) if $upcase;
    print $found;
  };
};

If you copy whatever text you want from the PDF into a file called e.g. source, then execute cat source | perl decrypt.pl > destination, then the file destination will contain the decrypted content:

[user@host tmp]$ echo 'Zdn az ~gfppbfjdf`hn' > source
[user@host tmp]$ cat source | perl decrypt.pl > destination
[user@host tmp]$ cat destination
She is unapproachable
[user@host tmp]$ 
Aaron Miller
  • 10,087