File: hmac_api.hrl

package info (click to toggle)
rabbitmq-server 3.3.5-1.1
  • links: PTS
  • area: main
  • in suites: jessie-kfreebsd
  • size: 12,004 kB
  • sloc: erlang: 78,203; python: 3,187; xml: 2,843; makefile: 903; sh: 831; java: 660; perl: 64; ruby: 63
file content (43 lines) | stat: -rw-r--r-- 1,956 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
-author("Hypernumbers Ltd <gordon@hypernumbers.com>").

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%                                                                          %%%
%%% Reference values for testing against Amazon documents                    %%%
%%%                                                                          %%%
%%% These need to be changed in production!                                  %%%
%%%                                                                          %%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-define(schema, "AWS").
%% defines the prefix for headers to be included in the signature
-define(headerprefix, "x-amz-").
%% defines the date header
-define(dateheader, "x-amz-date").

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%                                                                          %%%
%%% Default values for defining a generic API                                %%%
%%%                                                                          %%%
%%% Only change these if you alter the canonicalisation                      %%%
%%%                                                                          %%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%-define(schema, "MOCHIAPI").
%%-define(headerprefix, "x-mochiapi-").
%%-define(dateheader, "x-mochiapi-date").

%% a couple of keys for testing
%% these are taken from the document
%% % http://docs.amazonwebservices.com/AmazonS3/latest/dev/index.html?RESTAuthentication.html
%% they are not valid keys!
-define(publickey,  "0PN5J17HBGZHT7JJ3X82").
-define(privatekey, "uV3F3YluFJax1cknvbcGwgjvx4QpvB+leU8dUj2o").


-record(hmac_signature,
        {
          method,
          contentmd5,
          contenttype,
          date,
          headers,
          resource
        }).