aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/axolotl/account.hh14
-rw-r--r--include/axolotl/axolotl.hh14
-rw-r--r--include/axolotl/base64.hh14
-rw-r--r--include/axolotl/error.hh14
-rw-r--r--include/axolotl/memory.hh14
-rw-r--r--include/axolotl/pickle.hh14
-rw-r--r--include/axolotl/session.hh14
-rw-r--r--src/account.cpp14
-rw-r--r--src/axolotl.cpp16
-rw-r--r--src/base64.cpp14
-rw-r--r--src/cipher.cpp14
-rw-r--r--src/memory.cpp14
-rw-r--r--src/pickle.cpp14
-rw-r--r--src/session.cpp14
14 files changed, 197 insertions, 1 deletions
diff --git a/include/axolotl/account.hh b/include/axolotl/account.hh
index 54d96c3..54621fd 100644
--- a/include/axolotl/account.hh
+++ b/include/axolotl/account.hh
@@ -1,3 +1,17 @@
+/* Copyright 2015 OpenMarket Ltd
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
#ifndef AXOLOTL_ACCOUNT_HH_
#define AXOLOTL_ACCOUNT_HH_
diff --git a/include/axolotl/axolotl.hh b/include/axolotl/axolotl.hh
index 75c5eb5..4e8516a 100644
--- a/include/axolotl/axolotl.hh
+++ b/include/axolotl/axolotl.hh
@@ -1,3 +1,17 @@
+/* Copyright 2015 OpenMarket Ltd
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
#ifndef AXOLOTL_HH_
#define AXOLOTL_HH_
diff --git a/include/axolotl/base64.hh b/include/axolotl/base64.hh
index c322640..361a558 100644
--- a/include/axolotl/base64.hh
+++ b/include/axolotl/base64.hh
@@ -1,3 +1,17 @@
+/* Copyright 2015 OpenMarket Ltd
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
#ifndef AXOLOLT_BASE64_HH_
#define AXOLOLT_BASE64_HH_
diff --git a/include/axolotl/error.hh b/include/axolotl/error.hh
index b875784..781705e 100644
--- a/include/axolotl/error.hh
+++ b/include/axolotl/error.hh
@@ -1,3 +1,17 @@
+/* Copyright 2015 OpenMarket Ltd
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
#ifndef ERROR_HH_
#define ERROR_HH_
diff --git a/include/axolotl/memory.hh b/include/axolotl/memory.hh
index 8313a19..68b577d 100644
--- a/include/axolotl/memory.hh
+++ b/include/axolotl/memory.hh
@@ -1,3 +1,17 @@
+/* Copyright 2015 OpenMarket Ltd
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
#include <cstddef>
#include <cstdint>
diff --git a/include/axolotl/pickle.hh b/include/axolotl/pickle.hh
index a2de4f0..8134971 100644
--- a/include/axolotl/pickle.hh
+++ b/include/axolotl/pickle.hh
@@ -1,3 +1,17 @@
+/* Copyright 2015 OpenMarket Ltd
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
#ifndef AXOLOTL_PICKLE_HH_
#define AXOLOTL_PICKLE_HH_
diff --git a/include/axolotl/session.hh b/include/axolotl/session.hh
index aeaac7d..17f1653 100644
--- a/include/axolotl/session.hh
+++ b/include/axolotl/session.hh
@@ -1,3 +1,17 @@
+/* Copyright 2015 OpenMarket Ltd
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
#ifndef AXOLOTL_SESSION_HH_
#define AXOLOTL_SESSION_HH_
diff --git a/src/account.cpp b/src/account.cpp
index 95bafa8..3124312 100644
--- a/src/account.cpp
+++ b/src/account.cpp
@@ -1,3 +1,17 @@
+/* Copyright 2015 OpenMarket Ltd
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
#include "axolotl/account.hh"
#include "axolotl/pickle.hh"
diff --git a/src/axolotl.cpp b/src/axolotl.cpp
index f03a01c..2586204 100644
--- a/src/axolotl.cpp
+++ b/src/axolotl.cpp
@@ -1,3 +1,17 @@
+/* Copyright 2015 OpenMarket Ltd
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
#include "axolotl/axolotl.hh"
#include "axolotl/session.hh"
#include "axolotl/account.hh"
@@ -349,7 +363,7 @@ size_t axolotl_account_identity_keys(
AxolotlAccount * account,
void * identity_keys, size_t identity_key_length
) {
- std::size_t length = OUTPUT_KEY_LENGTH * 2 + 1;
+ std::size_t length = axolotl_account_identity_keys_length(account);
if (identity_key_length < length) {
from_c(account)->last_error =
axolotl::ErrorCode::OUTPUT_BUFFER_TOO_SMALL;
diff --git a/src/base64.cpp b/src/base64.cpp
index 6428424..6fafa44 100644
--- a/src/base64.cpp
+++ b/src/base64.cpp
@@ -1,3 +1,17 @@
+/* Copyright 2015 OpenMarket Ltd
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
#include "axolotl/base64.hh"
diff --git a/src/cipher.cpp b/src/cipher.cpp
index 8b496df..2d700b1 100644
--- a/src/cipher.cpp
+++ b/src/cipher.cpp
@@ -1,3 +1,17 @@
+/* Copyright 2015 OpenMarket Ltd
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
#include "axolotl/cipher.hh"
#include "axolotl/crypto.hh"
#include "axolotl/memory.hh"
diff --git a/src/memory.cpp b/src/memory.cpp
index 07e8de2..deb3076 100644
--- a/src/memory.cpp
+++ b/src/memory.cpp
@@ -1,3 +1,17 @@
+/* Copyright 2015 OpenMarket Ltd
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
#include "axolotl/memory.hh"
diff --git a/src/pickle.cpp b/src/pickle.cpp
index 43ef49c..1597326 100644
--- a/src/pickle.cpp
+++ b/src/pickle.cpp
@@ -1,3 +1,17 @@
+/* Copyright 2015 OpenMarket Ltd
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
#include "axolotl/pickle.hh"
diff --git a/src/session.cpp b/src/session.cpp
index 6d93326..7fb07e2 100644
--- a/src/session.cpp
+++ b/src/session.cpp
@@ -1,3 +1,17 @@
+/* Copyright 2015 OpenMarket Ltd
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
#include "axolotl/session.hh"
#include "axolotl/cipher.hh"
#include "axolotl/crypto.hh"