Skip to content

Commit

Permalink
Add missing includes in chaps_util/*
Browse files Browse the repository at this point in the history
Add missing imports to files in chaps_util/ folder. These required
includes were probably satisfied indirectly, but that's against the
style guide.

Bug: b:288880151
Change-Id: I7ea0196a5118faaa9c5eae4103d58578bd947682
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5171581
Reviewed-by: Michael Ershov <miersh@google.com>
Reviewed-by: Oleksandr Sarapulov <olsa@google.com>
Commit-Queue: Felipe Andrade <fsandrade@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1244014}
  • Loading branch information
Felipe Andrade authored and Chromium LUCI CQ committed Jan 8, 2024
1 parent 0090b38 commit 235535b
Show file tree
Hide file tree
Showing 14 changed files with 65 additions and 3 deletions.
3 changes: 3 additions & 0 deletions chromeos/ash/components/chaps_util/chaps_slot_session.cc
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@
#include <pkcs11.h>
#include <pkcs11t.h>

#include <memory>
#include <optional>

#include "base/location.h"
#include "base/logging.h"
#include "base/memory/ptr_util.h"
Expand Down
1 change: 1 addition & 0 deletions chromeos/ash/components/chaps_util/chaps_util.cc
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

#include "chromeos/ash/components/chaps_util/chaps_util.h"

#include <memory>
#include <ostream>

#include "base/functional/callback.h"
Expand Down
1 change: 1 addition & 0 deletions chromeos/ash/components/chaps_util/chaps_util.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
#define CHROMEOS_ASH_COMPONENTS_CHAPS_UTIL_CHAPS_UTIL_H_

#include <pk11pub.h>
#include <stdint.h>

#include <memory>
#include <vector>
Expand Down
4 changes: 4 additions & 0 deletions chromeos/ash/components/chaps_util/chaps_util_impl.cc
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,11 @@
#include <pk11pub.h>
#include <pkcs11.h>
#include <pkcs11t.h>
#include <stdint.h>

#include <optional>
#include <ostream>
#include <string>
#include <vector>

#include "base/check.h"
Expand All @@ -25,8 +27,10 @@
#include "chromeos/ash/components/chaps_util/pkcs12_validator.h"
#include "crypto/chaps_support.h"
#include "crypto/scoped_nss_types.h"
#include "third_party/boringssl/src/include/openssl/base.h"
#include "third_party/boringssl/src/include/openssl/mem.h"
#include "third_party/boringssl/src/include/openssl/pkcs8.h"
#include "third_party/boringssl/src/include/openssl/stack.h"

namespace chromeos {

Expand Down
3 changes: 3 additions & 0 deletions chromeos/ash/components/chaps_util/chaps_util_impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,10 @@
#ifndef CHROMEOS_ASH_COMPONENTS_CHAPS_UTIL_CHAPS_UTIL_IMPL_H_
#define CHROMEOS_ASH_COMPONENTS_CHAPS_UTIL_CHAPS_UTIL_IMPL_H_

#include <stdint.h>

#include <memory>
#include <string>
#include <vector>

#include "base/component_export.h"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,17 @@

#include <pkcs11t.h>
#include <secmodt.h>
#include <stdint.h>

#include <map>
#include <optional>
#include <utility>
#include <vector>

#include "base/base64.h"
#include "base/containers/span.h"
#include "base/files/file_util.h"
#include "base/memory/raw_ptr.h"
#include "chromeos/ash/components/chaps_util/chaps_slot_session.h"
#include "chromeos/ash/components/chaps_util/pkcs12_reader.h"
#include "crypto/nss_key_util.h"
Expand All @@ -24,7 +27,9 @@
#include "net/test/test_data_directory.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/boringssl/src/include/openssl/base.h"
#include "third_party/boringssl/src/include/openssl/bn.h"
#include "third_party/boringssl/src/include/openssl/stack.h"
#include "third_party/boringssl/src/include/openssl/x509.h"

namespace chromeos {
Expand Down
7 changes: 7 additions & 0 deletions chromeos/ash/components/chaps_util/key_helper.cc
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,14 @@
// found in the LICENSE file.

#include "chromeos/ash/components/chaps_util/key_helper.h"

#include <pk11pub.h>
#include <stdint.h>

#include <vector>

#include "base/hash/sha1.h"
#include "crypto/scoped_nss_types.h"
#include "net/cert/x509_util_nss.h"
#include "third_party/boringssl/src/include/openssl/bn.h"
#include "third_party/boringssl/src/include/openssl/bytestring.h"
Expand Down
10 changes: 9 additions & 1 deletion chromeos/ash/components/chaps_util/pkcs12_reader.cc
Original file line number Diff line number Diff line change
@@ -1,15 +1,23 @@
// Copyright 2023 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "chromeos/ash/components/chaps_util/pkcs12_reader.h"

#include <stdint.h>

#include <string>
#include <vector>

#include "base/containers/span.h"
#include "chromeos/ash/components/chaps_util/key_helper.h"
#include "chromeos/ash/components/chaps_util/pkcs12_reader.h"
#include "crypto/nss_util.h"
#include "net/cert/x509_util_nss.h"
#include "third_party/boringssl/src/include/openssl/base.h"
#include "third_party/boringssl/src/include/openssl/bn.h"
#include "third_party/boringssl/src/include/openssl/mem.h"
#include "third_party/boringssl/src/include/openssl/pkcs8.h"
#include "third_party/boringssl/src/include/openssl/stack.h"

namespace chromeos {

Expand Down
7 changes: 5 additions & 2 deletions chromeos/ash/components/chaps_util/pkcs12_reader.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,20 @@
#ifndef CHROMEOS_ASH_COMPONENTS_CHAPS_UTIL_PKCS12_READER_H_
#define CHROMEOS_ASH_COMPONENTS_CHAPS_UTIL_PKCS12_READER_H_

#include <cstdint>
#include <nss/certt.h>
#include <stdint.h>

#include <string>
#include <vector>

#include <nss/certt.h>
#include "base/component_export.h"
#include "base/containers/span.h"
#include "chromeos/ash/components/chaps_util/chaps_slot_session.h"
#include "crypto/scoped_nss_types.h"
#include "net/cert/x509_certificate.h"
#include "third_party/boringssl/src/include/openssl/base.h"
#include "third_party/boringssl/src/include/openssl/pkcs7.h"
#include "third_party/boringssl/src/include/openssl/stack.h"

namespace chromeos {

Expand Down
9 changes: 9 additions & 0 deletions chromeos/ash/components/chaps_util/pkcs12_reader_unittest.cc
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,28 @@
#include "chromeos/ash/components/chaps_util/pkcs12_reader.h"

#include <pk11pub.h>
#include <stdint.h>

#include <memory>
#include <string>
#include <vector>

#include "base/base64.h"
#include "base/containers/span.h"
#include "chromeos/ash/components/chaps_util/key_helper.h"
#include "crypto/scoped_test_nss_db.h"
#include "net/cert/x509_certificate.h"
#include "net/test/cert_test_util.h"
#include "net/test/test_data_directory.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/boringssl/src/include/openssl/base.h"
#include "third_party/boringssl/src/include/openssl/bn.h"
#include "third_party/boringssl/src/include/openssl/ec_key.h"
#include "third_party/boringssl/src/include/openssl/evp.h"
#include "third_party/boringssl/src/include/openssl/mem.h"
#include "third_party/boringssl/src/include/openssl/rsa.h"
#include "third_party/boringssl/src/include/openssl/stack.h"
#include "third_party/boringssl/src/include/openssl/x509.h"

namespace chromeos {
Expand Down
9 changes: 9 additions & 0 deletions chromeos/ash/components/chaps_util/pkcs12_validator.cc
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,20 @@

#include "chromeos/ash/components/chaps_util/pkcs12_validator.h"

#include <stdint.h>

#include <memory>
#include <string>
#include <vector>

#include "base/containers/span.h"
#include "base/logging.h"
#include "base/strings/string_number_conversions.h"
#include "chromeos/ash/components/chaps_util/pkcs12_reader.h"
#include "third_party/boringssl/src/include/openssl/base.h"
#include "third_party/boringssl/src/include/openssl/mem.h"
#include "third_party/boringssl/src/include/openssl/pkcs8.h"
#include "third_party/boringssl/src/include/openssl/stack.h"

namespace chromeos {
namespace {
Expand Down
4 changes: 4 additions & 0 deletions chromeos/ash/components/chaps_util/pkcs12_validator.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,15 @@
#ifndef CHROMEOS_ASH_COMPONENTS_CHAPS_UTIL_PKCS12_VALIDATOR_H_
#define CHROMEOS_ASH_COMPONENTS_CHAPS_UTIL_PKCS12_VALIDATOR_H_

#include <string>
#include <vector>

#include "base/memory/raw_ptr_cast.h"
#include "base/memory/raw_ptr_exclusion.h"
#include "base/memory/raw_ref.h"
#include "chromeos/ash/components/chaps_util/pkcs12_reader.h"
#include "third_party/boringssl/src/include/openssl/base.h"
#include "third_party/boringssl/src/include/openssl/stack.h"

namespace chromeos {

Expand Down
3 changes: 3 additions & 0 deletions chromeos/ash/components/chaps_util/test_util.cc
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,18 @@
#include "chromeos/ash/components/chaps_util/test_util.h"

#include <pk11pub.h>
#include <stdint.h>

#include <memory>
#include <string>
#include <vector>

#include "base/functional/bind.h"
#include "base/functional/callback_forward.h"
#include "base/memory/weak_ptr.h"
#include "chromeos/ash/components/chaps_util/chaps_util.h"
#include "crypto/nss_key_util.h"
#include "crypto/scoped_nss_types.h"

namespace chromeos {

Expand Down
2 changes: 2 additions & 0 deletions chromeos/ash/components/chaps_util/test_util.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
#define CHROMEOS_ASH_COMPONENTS_CHAPS_UTIL_TEST_UTIL_H_

#include <pk11pub.h>
#include <stdint.h>

#include <memory>
#include <string>
Expand All @@ -14,6 +15,7 @@
#include "base/functional/callback.h"
#include "base/memory/weak_ptr.h"
#include "chromeos/ash/components/chaps_util/chaps_util.h"
#include "crypto/scoped_nss_types.h"

namespace chromeos {

Expand Down

0 comments on commit 235535b

Please sign in to comment.