Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: abedra/libvault
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 0.21.0
Choose a base ref
...
head repository: abedra/libvault
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref

Commits on Jun 6, 2020

  1. Create CODE_OF_CONDUCT.md

    abedra authored Jun 6, 2020
    Copy the full SHA
    4cf1924 View commit details

Commits on Jun 7, 2020

  1. Copy the full SHA
    adc2dc0 View commit details
  2. Copy the full SHA
    71dc818 View commit details
  3. Copy the full SHA
    72db478 View commit details
  4. Version bump

    abedra committed Jun 7, 2020
    Copy the full SHA
    2bf784b View commit details
  5. Copy the full SHA
    9675c0a View commit details
  6. Copy the full SHA
    c25ba9d View commit details
  7. Version bump

    abedra committed Jun 7, 2020
    Copy the full SHA
    37804a0 View commit details

Commits on Jun 12, 2020

  1. Copy the full SHA
    28364a2 View commit details
  2. Make gcov optional. Closes #47

    abedra committed Jun 12, 2020
    Copy the full SHA
    c7c8418 View commit details
  3. Version bump

    abedra committed Jun 12, 2020
    Copy the full SHA
    9db0afa View commit details

Commits on Jun 13, 2020

  1. Copy the full SHA
    094ff04 View commit details
  2. Version bump

    abedra committed Jun 13, 2020
    Copy the full SHA
    c4e8e49 View commit details

Commits on Jun 20, 2020

  1. Add proper tiny types (#51)

    abedra authored Jun 20, 2020
    Copy the full SHA
    51b987b View commit details
  2. script cleanup

    abedra committed Jun 20, 2020
    Copy the full SHA
    a8e5fd4 View commit details
  3. Copy the full SHA
    a478b19 View commit details
  4. Copy the full SHA
    f2f9c32 View commit details
  5. Copy the full SHA
    04233de View commit details
  6. Copy the full SHA
    2dd476b View commit details

Commits on Jul 5, 2020

  1. Copy the full SHA
    2b164e7 View commit details
  2. Copy the full SHA
    6f624f5 View commit details
  3. Copy the full SHA
    90c96c7 View commit details
  4. Copy the full SHA
    13beae3 View commit details
  5. Version bump

    abedra committed Jul 5, 2020
    Copy the full SHA
    eb432b7 View commit details

Commits on Jul 18, 2020

  1. Copy the full SHA
    b5d5626 View commit details

Commits on Jul 19, 2020

  1. Copy the full SHA
    acaa5ea View commit details
  2. Adds support for sys/pprof

    abedra committed Jul 19, 2020
    Copy the full SHA
    c33e606 View commit details
  3. Copy the full SHA
    f518479 View commit details
  4. Copy the full SHA
    5d49530 View commit details
  5. Copy the full SHA
    f2a40a1 View commit details
  6. Version bump

    abedra committed Jul 19, 2020
    Copy the full SHA
    fa581a8 View commit details

Commits on Nov 12, 2020

  1. Create veracode-analysis.yml

    abedra authored Nov 12, 2020
    Copy the full SHA
    b30594c View commit details

Commits on Nov 13, 2020

  1. Fix README.md

    abedra committed Nov 13, 2020
    Copy the full SHA
    f87e9d9 View commit details

Commits on Nov 14, 2020

  1. Copy the full SHA
    5a5c86b View commit details
  2. Copy the full SHA
    d1ae823 View commit details

Commits on Nov 15, 2020

  1. Copy the full SHA
    4d58661 View commit details

Commits on Nov 16, 2020

  1. Copy the full SHA
    915d0b2 View commit details
  2. Copy the full SHA
    eff1499 View commit details
  3. Copy the full SHA
    2b2b98e View commit details

Commits on Nov 20, 2020

  1. Create cmake.yml

    abedra authored Nov 20, 2020
    Copy the full SHA
    d7ced3e View commit details
  2. Update cmake.yml

    abedra authored Nov 20, 2020
    Copy the full SHA
    95fff9a View commit details
  3. Update cmake.yml

    abedra authored Nov 20, 2020
    Copy the full SHA
    c8ea8a2 View commit details

Commits on Nov 21, 2020

  1. Update cmake.yml

    abedra authored Nov 21, 2020
    Copy the full SHA
    0a86c6d View commit details
  2. Update cmake.yml

    abedra authored Nov 21, 2020
    Copy the full SHA
    6602c34 View commit details
  3. Update cmake.yml

    abedra authored Nov 21, 2020
    Copy the full SHA
    919286f View commit details
  4. Update README.md

    abedra authored Nov 21, 2020
    Copy the full SHA
    714a633 View commit details
  5. Delete .travis.yml

    abedra authored Nov 21, 2020
    Copy the full SHA
    a1587a5 View commit details
  6. Delete veracode-analysis.yml

    abedra authored Nov 21, 2020
    Copy the full SHA
    1c22fd7 View commit details
  7. Copy the full SHA
    096816f View commit details
  8. Copy the full SHA
    ead1455 View commit details
Showing with 12,449 additions and 2,223 deletions.
  1. +119 −0 .github/workflows/cmake.yml
  2. +4 −2 .gitignore
  3. +0 −1 .muse.toml
  4. +0 −19 .travis.yml
  5. +175 −71 CMakeLists.txt
  6. +76 −0 CODE_OF_CONDUCT.md
  7. +9 −0 CPPLINT.cfg
  8. +125 −87 README.md
  9. +5 −0 VaultConfig.cmake.in
  10. +1 −0 compile_commands.json
  11. +0 −2 example/postgresql/database.sql → docker/create_tables.sql
  12. +22 −1 docker/docker-compose.yml
  13. +0 −11 example/Makefile
  14. +0 −19 example/README.md
  15. +18 −0 example/administration/audit/Makefile
  16. +30 −0 example/administration/audit/example.cpp
  17. +18 −0 example/administration/auth/Makefile
  18. +25 −0 example/administration/auth/example.cpp
  19. +18 −0 example/administration/mounts/Makefile
  20. +31 −0 example/administration/mounts/example.cpp
  21. +18 −0 example/administration/system/Makefile
  22. +25 −0 example/administration/system/example.cpp
  23. +18 −0 example/authentication/approle/Makefile
  24. +44 −0 example/authentication/approle/example.cpp
  25. +1 −0 example/authentication/jwt/.gitignore
  26. +20 −0 example/authentication/jwt/Makefile
  27. +208 −0 example/authentication/jwt/base.h
  28. +79 −0 example/authentication/jwt/example.cpp
  29. +3,037 −0 example/authentication/jwt/jwt.h
  30. +1,200 −0 example/authentication/jwt/picojson/picojson.h
  31. +0 −36 example/example.cpp
  32. +0 −11 example/postgresql/requirements.txt
  33. +0 −28 example/postgresql/select.py
  34. +0 −32 example/rabbitmq/consume.py
  35. +0 −3 example/rabbitmq/requirements.txt
  36. +18 −0 example/secrets/key_value/Makefile
  37. +62 −0 example/secrets/key_value/example.cpp
  38. +18 −0 example/secrets/pki/custom_path/Makefile
  39. +60 −0 example/secrets/pki/custom_path/example.cpp
  40. +18 −0 example/secrets/pki/default_path/Makefile
  41. +77 −0 example/secrets/pki/default_path/example.cpp
  42. +22 −0 example/secrets/postgres/Makefile
  43. +9 −0 example/secrets/postgres/config.json
  44. +104 −0 example/secrets/postgres/example.cpp
  45. +185 −0 example/shared/shared.h
  46. +1,990 −428 include/VaultClient.h
  47. +0 −12 lgtm.yml
  48. +26 −13 script/bootstrap
  49. +0 −15 script/fetch_vault
  50. +0 −6 script/get_secret
  51. +0 −5 script/initialize
  52. +0 −7 script/install_approle
  53. +0 −6 script/install_database
  54. +0 −7 script/install_key_value
  55. +0 −6 script/install_pki
  56. +0 −7 script/install_policy
  57. +0 −6 script/install_rabbitmq
  58. +0 −6 script/install_totp
  59. +0 −6 script/install_transit
  60. +0 −15 script/setup_approle
  61. +0 −7 script/setup_key_value
  62. +0 −8 script/setup_transit
  63. +0 −5 script/status
  64. +0 −10 script/unseal
  65. +0 −5 script/vault
  66. +0 −12 script/wrap_secret
  67. +181 −0 src/auth/AWS.cpp
  68. +7 −4 src/auth/AliCloud.cpp
  69. +61 −88 src/auth/AppRole.cpp
  70. +0 −27 src/auth/AppRoleStrategy.cpp
  71. +40 −0 src/auth/Azure.cpp
  72. +41 −0 src/auth/CloudFoundry.cpp
  73. +38 −0 src/auth/GitHub.cpp
  74. +53 −0 src/auth/GoogleCloud.cpp
  75. +46 −0 src/auth/JwtOidc.cpp
  76. +52 −0 src/auth/Kerberos.cpp
  77. +36 −0 src/auth/Kubernetes.cpp
  78. +65 −0 src/auth/Ldap.cpp
  79. +0 −27 src/auth/LdapStrategy.cpp
  80. +35 −0 src/auth/OCI.cpp
  81. +54 −0 src/auth/Okta.cpp
  82. +31 −0 src/auth/Radius.cpp
  83. +45 −0 src/auth/Tls.cpp
  84. +106 −0 src/auth/Tokens.cpp
  85. +45 −0 src/auth/UserPass.cpp
  86. +19 −0 src/auth/strategies/AppRoleStrategy.cpp
  87. +18 −0 src/auth/strategies/JwtStrategy.cpp
  88. +23 −0 src/auth/strategies/LdapStrategy.cpp
  89. +10 −0 src/auth/strategies/TlsStrategy.cpp
  90. +6 −6 src/auth/{ → strategies}/WrappedSecretAppRoleStrategy.cpp
  91. +32 −9 src/domain/ConfigBuilder.cpp
  92. +38 −33 src/domain/VaultClient.cpp
  93. +66 −0 src/engines/AWS.cpp
  94. +36 −15 src/engines/ActiveDirectory.cpp
  95. +12 −6 src/engines/AliCloud.cpp
  96. +41 −0 src/engines/Azure.cpp
  97. +39 −0 src/engines/Consul.cpp
  98. +6 −19 src/engines/Cubbyhole.cpp
  99. +28 −13 src/engines/Database.cpp
  100. +69 −0 src/engines/GoogleCloud.cpp
  101. +108 −0 src/engines/GoogleCloudKms.cpp
  102. +99 −123 src/engines/KeyValue.cpp
  103. +93 −0 src/engines/Kmip.cpp
  104. +39 −0 src/engines/MongoDBAtlas.cpp
  105. +53 −0 src/engines/Nomad.cpp
  106. +52 −0 src/engines/OpenLDAP.cpp
  107. +70 −44 src/engines/Pki.cpp
  108. +14 −7 src/engines/RabbitMq.cpp
  109. +19 −10 src/engines/SSH.cpp
  110. +13 −29 src/engines/Totp.cpp
  111. +218 −0 src/engines/Transform.cpp
  112. +74 −37 src/engines/Transit.cpp
  113. +66 −0 src/engines/identity/Entity.cpp
  114. +30 −0 src/engines/identity/EntityAlias.cpp
  115. +56 −0 src/engines/identity/Group.cpp
  116. +30 −0 src/engines/identity/GroupAlias.cpp
  117. +90 −0 src/engines/identity/IdentityTokens.cpp
  118. +15 −0 src/engines/identity/Lookup.cpp
  119. +35 −22 src/support/Base64.cpp
  120. +30 −0 src/support/CreateJson.h
  121. +113 −135 src/support/HttpClient.cpp
  122. +234 −110 src/support/HttpConsumer.cpp
  123. +89 −37 src/system/Sys.cpp
  124. +6 −4 src/system/audit/Audit.cpp
  125. +29 −0 src/system/auditing/Auditing.cpp
  126. +16 −12 src/system/auth/Auth.cpp
  127. +31 −0 src/system/config/ControlGroup.cpp
  128. +18 −0 src/system/config/Cors.cpp
  129. +22 −0 src/system/config/UI.cpp
  130. +17 −0 src/system/counters/Counters.cpp
  131. +23 −0 src/system/generate_root/GenerateRoot.cpp
  132. +14 −0 src/system/init/Init.cpp
  133. +43 −0 src/system/leases/Leases.cpp
  134. +14 −0 src/system/license/License.cpp
  135. +20 −0 src/system/mfa/Duo.cpp
  136. +17 −0 src/system/mfa/Mfa.cpp
  137. +20 −0 src/system/mfa/Okta.cpp
  138. +20 −0 src/system/mfa/PingId.cpp
  139. +38 −0 src/system/mfa/Totp.cpp
  140. +41 −0 src/system/mounts/Mounts.cpp
  141. +22 −0 src/system/namespaces/Namespaces.cpp
  142. +30 −0 src/system/plugins/Plugins.cpp
  143. +29 −0 src/system/policies/ACL.cpp
  144. +29 −0 src/system/policies/EGP.cpp
  145. +28 −0 src/system/policies/Policies.cpp
  146. +29 −0 src/system/policies/RGP.cpp
  147. +29 −0 src/system/policy/Policy.cpp
  148. +33 −0 src/system/pprof/Pprof.cpp
  149. +27 −0 src/system/raw/Raw.cpp
  150. +13 −0 src/system/sealwrap/Sealwrap.cpp
  151. +13 −0 src/system/tools/Tools.cpp
  152. +13 −14 test/integration/AppRoleTests.cpp
  153. +5 −8 test/integration/AuthenticationStrategies.cpp
  154. +155 −127 test/integration/TestHelpers.h
  155. +258 −0 test/integration/TokensTests.cpp
  156. +15 −21 test/integration/engines/CubbyholeTests.cpp
  157. +29 −29 test/integration/engines/DatabaseTests.cpp
  158. +39 −15 test/integration/engines/KeyValueTests.cpp
  159. +42 −46 test/integration/engines/PkiTests.cpp
  160. +14 −17 test/integration/engines/RabbitMqTests.cpp
  161. +38 −40 test/integration/engines/TotpTests.cpp
  162. +49 −45 test/integration/engines/TransitTests.cpp
  163. +18 −16 test/integration/system/AuthTests.cpp
  164. +37 −44 test/integration/system/SysTests.cpp
  165. +132 −69 test/test.cpp
119 changes: 119 additions & 0 deletions .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,119 @@
name: CMake

on: [push]

env:
BUILD_TYPE: Release

jobs:
gcc-build:
name: GCC ${{ matrix.version }}
runs-on: ubuntu-22.04

strategy:
fail-fast: false
matrix:
version: ['9', '10', '11', '12', '13']

env:
CC: gcc-${{ matrix.version }}
CXX: g++-${{ matrix.version }}

steps:
- uses: actions/checkout@v4

- name: Install dependencies
run: sudo apt-get install libcurl4-openssl-dev

- name: Install compiler
run: |
sudo apt-get install software-properties-common -y
sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y
sudo apt-get update
sudo apt-get install -y g++-${{ matrix.version }} libbsd-dev uuid-dev
- name: Install Catch2
run: |
git clone https://github.com/catchorg/Catch2.git
cd Catch2
git checkout v2.x
cmake -Bbuild -H. -DBUILD_TESTING=OFF
cmake --build build/
cd build && sudo make install
- name: Create Build Environment
run: cmake -E make_directory ${{runner.workspace}}/build

- name: Configure CMake
shell: bash
working-directory: ${{runner.workspace}}/build
run: cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE

- name: Build
working-directory: ${{runner.workspace}}/build
shell: bash
# Execute the build. You can specify a specific target with "--target <NAME>"
run: cmake --build . --config $BUILD_TYPE

- name: Test
working-directory: ${{runner.workspace}}/build
shell: bash
# Execute tests defined by the CMake configuration.
# See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail
run: ctest -C $BUILD_TYPE

clang-build:
name: Clang ${{ matrix.version }}
runs-on: ubuntu-22.04

strategy:
fail-fast: false
matrix:
version: ['11', '12', '13', '14', '15']

env:
CC: clang-${{ matrix.version }}
CXX: clang++-${{ matrix.version }}

steps:
- uses: actions/checkout@v4

- name: Install dependencies
run: sudo apt-get install libcurl4-openssl-dev

- name: Install compiler
run: |
curl -L https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add -
sudo add-apt-repository "deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy main"
sudo apt-get update
sudo apt-get install -y clang-${{ matrix.version }} libstdc++-11-dev libbsd-dev uuid-dev
- name: Install Catch2
run: |
git clone https://github.com/catchorg/Catch2.git
cd Catch2
git checkout v2.x
cmake -Bbuild -H. -DBUILD_TESTING=OFF
cmake --build build/
cd build && sudo make install
- name: Create Build Environment
run: cmake -E make_directory ${{runner.workspace}}/build

- name: Configure CMake
shell: bash
working-directory: ${{runner.workspace}}/build
run: cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE

- name: Build
working-directory: ${{runner.workspace}}/build
shell: bash
# Execute the build. You can specify a specific target with "--target <NAME>"
run: cmake --build . --config $BUILD_TYPE

- name: Test
working-directory: ${{runner.workspace}}/build
shell: bash
# Execute tests defined by the CMake configuration.
# See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail
run: ctest -C $BUILD_TYPE
6 changes: 4 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -4,11 +4,13 @@ CMakeCache.txt
CMakeFiles
./Makefile
cmake_install.cmake
example/example
build
*.o
data
bin
operator.txt
.env
venv
venv
*.gch
example/**/example
.cache
1 change: 0 additions & 1 deletion .muse.toml

This file was deleted.

19 changes: 0 additions & 19 deletions .travis.yml

This file was deleted.

Loading