From d008238b16416daf46f859e611f4c84d0a646523 Mon Sep 17 00:00:00 2001 From: Magnus Ahltorp Date: Tue, 21 Oct 2014 17:16:50 +0200 Subject: Break include dependency on plop.hrl Conflicts: src/catlfish.erl --- README.md | 2 +- src/catlfish.erl | 2 -- src/v1.erl | 11 ++++------- 3 files changed, 5 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index 83b9167..514e87f 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ catlfish is a Certificate Transparency log server (RFC 6962). # Compile - $ CTROOT=.. make + $ make $ make release # Requirements diff --git a/src/catlfish.erl b/src/catlfish.erl index cd871f5..66141d8 100644 --- a/src/catlfish.erl +++ b/src/catlfish.erl @@ -4,8 +4,6 @@ -module(catlfish). -export([add_chain/2, entries/2, entry_and_proof/2]). -export([known_roots/0, update_known_roots/0]). --include("$CTROOT/plop/include/plop.hrl"). --include_lib("eunit/include/eunit.hrl"). -define(PROTOCOL_VERSION, 0). diff --git a/src/v1.erl b/src/v1.erl index 46b5235..6b973fc 100644 --- a/src/v1.erl +++ b/src/v1.erl @@ -9,8 +9,6 @@ 'get-sth-consistency'/3, 'get-proof-by-hash'/3, 'get-entries'/3, 'get-roots'/3, 'get-entry-and-proof'/3]). --include("$CTROOT/plop/include/plop.hrl"). - %% Public functions, i.e. part of URL. 'add-chain'(SessionID, _Env, Input) -> R = case (catch jiffy:decode(Input)) of @@ -40,11 +38,10 @@ niy(SessionID). 'get-sth'(SessionID, _Env, _Input) -> - #sth{ - treesize = Treesize, - timestamp = Timestamp, - roothash = Roothash, - signature = Signature} = plop:sth(), + { Treesize, + Timestamp, + Roothash, + Signature} = plop:sth(), R = [{tree_size, Treesize}, {timestamp, Timestamp}, {sha256_root_hash, base64:encode(Roothash)}, -- cgit v1.1