Acme-DRM

 view release on metacpan or  search on metacpan

README  view on Meta::CPAN

34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
  digital media stream, and steal your Intellectual Property. Our solution
  is to use the media itself as the key. This function conveniently takes
  only the media as a single argument, and automatically XORs the
  datastream with a copy of itself, rendering the stream almost completely
  unrecoverable without the key: the media itself. This is virtually
  hacker-proof, except for one exception: the encrypted datastream is
  exactly the same length as the original data, but this is almost never
  probably a weakness. This algorithm does guarantee that your original
  data will not be recoverable from the encrypted stream without the
  proper key. Additionally, use of an incorrect key will not provide
  hackers with any sort of clue that they have guessed an incorrect key.
 
doubleROT128
  This function exists to provide a method by which you can protect your
  Intellectual Property under the DMCA, without imposing the difficulty of
  implementing a separate, potentially insecure decryption algorithm in
  your secure media playback application. Simply pass your digital media
  to this function, and it will output an encrypted stream, conveniently
  passed twice internally through a strong ROT-128 encryption algorithm.
  The resulting encrypted content cannot be legally decrypted by a hacker,
  since you encrypted it to protect it from hackers and pirates. Further,

lib/Acme/DRM.pm  view on Meta::CPAN

52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
push( @EXPORT_OK, '&doubleROT128' );
 
=back
 
=head1 FUNCTIONS
 
=head2 secureXOR
 
XOR is an extremely convenient method for encrypting a digital media stream.  Given any two of the a) original data, b) encryption key, and c) encrypted data, you get the third item.  Unfortunately, hackers have compromised the effectiveness of this ...
The answer is to use a variable key, however, key distribution becomes a difficult proposition.  If the key is distributed in the clear, pirates can simply decrypt the digital media stream, and steal your B<Intellectual Property>.  Our solution is to...
 
=cut
 
sub secureXOR {
 
  # Get the first argument
  my $data = shift;
 
  # Make sure we really got something
  unless ( defined($data) ) {



( run in 0.541 second using v1.01-cache-2.11-cpan-26ccb49234f )