Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
56 commits
Select commit Hold shift + click to select a range
9674fae
ci: Update CI/CD with a support for testing replacement of native SDK…
tomasz-blasz Aug 28, 2025
3d22251
feat(cpp): Thunder removal (#:422)
tomasz-blasz Oct 23, 2025
6eb26ab
Add component tests (#:423)
vladimir-rangelov Oct 27, 2025
5fddbb3
feat: thunder post removal (#:424)
tomasz-blasz Oct 28, 2025
b4c699b
build: Fix absolute paths (#:427)
tomasz-blasz Oct 29, 2025
834ad22
feat(cpp): Change initialization of the transport (#:428)
tomasz-blasz Oct 29, 2025
a6f3791
feat: Lifecycle 2.0 (#:432)
damcav64 Nov 4, 2025
024461b
feat(cpp): Compile all test apps at once (#:433)
tomasz-blasz Nov 4, 2025
cafa305
fix(cpp): Use cmake way to control shared/static library (#:434)
tomasz-blasz Nov 4, 2025
d1d7424
fix: Update Lifecycle 2.0 to schema, update UTs (#:435)
tomasz-blasz Nov 4, 2025
f791d74
feat(cpp): Update to changes around config (#:436)
tomasz-blasz Nov 5, 2025
b50890f
build: Update transport version (#:437)
tomasz-blasz Nov 5, 2025
b9cae53
Add lifecycle2 component tests (#:438)
vladimir-rangelov Nov 6, 2025
dd33526
feat(cpp): Lifecycle2 event (#:441)
tomasz-blasz Nov 6, 2025
8d7489b
feat(cpp): Update version of transport (#:440)
tomasz-blasz Nov 6, 2025
9abaaf6
fix: Lifecycle (#:443)
tomasz-blasz Nov 7, 2025
1e4aeaf
test: With a fix in mock-fb, events can be emitted as events (#:444)
tomasz-blasz Nov 12, 2025
6af984d
ci: Add component tests (#:448)
tomasz-blasz Nov 14, 2025
8e0532b
fix: Set pedantic compilation (#:450)
tomasz-blasz Nov 17, 2025
2237e05
feat: New payload spec (#:454)
tomasz-blasz Nov 18, 2025
7509af8
feat: Update namings (#:455)
tomasz-blasz Nov 19, 2025
ca74133
feat: Device API (#:451)
damcav64 Nov 20, 2025
4473c36
feat: Advertising api (#:457)
damcav64 Nov 20, 2025
9eefb1d
Stats API (#:453)
damcav64 Nov 20, 2025
f22fa6b
feat: Accessibility API (#:452)
damcav64 Nov 20, 2025
8c32429
Refactor: Update code (#:459)
tomasz-blasz Nov 21, 2025
53c8178
feat: Presentation API (#:461)
tomasz-blasz Nov 21, 2025
428360b
feat: Clean up code, update to changes in transport (#:462)
tomasz-blasz Nov 24, 2025
42fbbe0
feat: Update clang formatter, format code, add a checker in ci (#:465)
tomasz-blasz Nov 24, 2025
885e33d
feat: compilation warnings (#:464)
tomasz-blasz Nov 24, 2025
722fe9f
feat: Update around versioning (#:467)
tomasz-blasz Nov 25, 2025
0dc3085
feat: Update demo app with presentation (#:466)
tomasz-blasz Nov 25, 2025
3094199
feat: Set transport version to be used (#:468)
tomasz-blasz Nov 25, 2025
50d5b9e
docs: Add License file (#:469)
tomasz-blasz Nov 26, 2025
6907317
feat: Component Tests for Accessibility API (#:470)
tomasz-blasz Nov 26, 2025
c677889
feat: Device.chipsetId (#:476)
damcav64 Nov 27, 2025
d342ce8
feat: Display API (#:474)
damcav64 Nov 27, 2025
22b9ebf
feat: Localization API (#:477)
damcav64 Nov 27, 2025
688fb30
test: Editorial
tomasz-blasz Nov 28, 2025
7c3c37a
feat: Use Transport v21
tomasz-blasz Nov 28, 2025
976eec9
feat: Remove not agreed APIs
tomasz-blasz Dec 1, 2025
8768bda
ci: Add test coverage
tomasz-blasz Dec 1, 2025
cb4f3d7
ci: Make logical chain
tomasz-blasz Dec 1, 2025
aec10c9
test: Update payload to JSON-RPC compliant params with an array (#:484)
tomasz-blasz Dec 2, 2025
44cc51a
Sync JS and CPP components for tests (#:486)
vladimir-rangelov Dec 3, 2025
5ac502c
ci: Extend scope of coverage report (#:485)
tomasz-blasz Dec 3, 2025
caca985
fix: Update internal type
tomasz-blasz Dec 3, 2025
f7633f4
build: Move headers as they are installed
tomasz-blasz Dec 3, 2025
1e4d869
feat: Use FetchContent for the Transport if not installed
tomasz-blasz Dec 3, 2025
a739b20
build: Transport v22
tomasz-blasz Dec 3, 2025
86b4407
test: Extend tests with negative scenarios (#:480)
damcav64 Dec 4, 2025
ff94826
feat: Transport v23
tomasz-blasz Dec 5, 2025
4256851
build: When tests enabled, link against compiled lib, not installed one
tomasz-blasz Dec 15, 2025
3c0c825
feat: Use Transport v24
tomasz-blasz Dec 15, 2025
b38d12d
ci: Re-enable CI workflow
tomasz-blasz Dec 11, 2025
c126c58
ci: Update to changes in repository layout
tomasz-blasz Dec 11, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
186 changes: 186 additions & 0 deletions .clang-format
Original file line number Diff line number Diff line change
@@ -0,0 +1,186 @@
# vim: ft=yaml
Language: Cpp
# BasedOnStyle: LLVM
AccessModifierOffset: -4
AlignAfterOpenBracket: Align
AlignConsecutiveMacros:
Enabled: false
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: false
AlignFunctionPointers: false
PadOperators: true
AlignConsecutiveAssignments:
Enabled: false
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: false
AlignFunctionPointers: false
PadOperators: true
AlignConsecutiveBitFields:
Enabled: false
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: false
AlignFunctionPointers: false
PadOperators: true
AlignConsecutiveDeclarations:
Enabled: false
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: false
AlignFunctionPointers: false
PadOperators: true
AlignEscapedNewlines: Right
AlignOperands: Align
AlignTrailingComments: true
AllowAllArgumentsOnNextLine: true
AllowAllConstructorInitializersOnNextLine: true
AllowAllParametersOfDeclarationOnNextLine: true
AllowShortEnumsOnASingleLine: true
AllowShortBlocksOnASingleLine: Never
AllowShortCaseLabelsOnASingleLine: false
AllowShortFunctionsOnASingleLine: Inline
AllowShortLambdasOnASingleLine: All
AllowShortIfStatementsOnASingleLine: Never
AllowShortLoopsOnASingleLine: false
AlwaysBreakAfterDefinitionReturnType: None
AlwaysBreakAfterReturnType: None
AlwaysBreakBeforeMultilineStrings: false
AlwaysBreakTemplateDeclarations: MultiLine
AttributeMacros:
- __capability
BinPackArguments: true
BinPackParameters: true
BitFieldColonSpacing: Both
BraceWrapping:
AfterCaseLabel: false
AfterClass: false
AfterControlStatement: Never
AfterEnum: false
AfterFunction: false
AfterNamespace: false
AfterObjCDeclaration: false
AfterStruct: false
AfterUnion: false
AfterExternBlock: false
BeforeCatch: false
BeforeElse: false
BeforeLambdaBody: false
BeforeWhile: false
IndentBraces: false
SplitEmptyFunction: true
SplitEmptyRecord: true
SplitEmptyNamespace: true
BreakBeforeBinaryOperators: None
BreakBeforeConceptDeclarations: true
BreakBeforeBraces: Allman
BreakBeforeInheritanceComma: false
BreakInheritanceList: BeforeColon
BreakBeforeTernaryOperators: true
BreakConstructorInitializersBeforeComma: false
BreakConstructorInitializers: BeforeColon
BreakAfterJavaFieldAnnotations: false
BreakStringLiterals: true
ColumnLimit: 120
CommentPragmas: "^ IWYU pragma:"
CompactNamespaces: false
ConstructorInitializerAllOnOneLineOrOnePerLine: false
ConstructorInitializerIndentWidth: 4
ContinuationIndentWidth: 4
Cpp11BracedListStyle: true
DeriveLineEnding: true
DerivePointerAlignment: false
DisableFormat: false
EmptyLineBeforeAccessModifier: LogicalBlock
ExperimentalAutoDetectBinPacking: false
FixNamespaceComments: true
ForEachMacros:
- foreach
- Q_FOREACH
- BOOST_FOREACH
IncludeBlocks: Preserve
IncludeCategories:
- Regex: ^"(llvm|llvm-c|clang|clang-c)/
Priority: 2
SortPriority: 0
CaseSensitive: false
- Regex: ^(<|"(gtest|gmock|isl|json)/)
Priority: 3
SortPriority: 0
CaseSensitive: false
- Regex: .*
Priority: 1
SortPriority: 0
CaseSensitive: false
IncludeIsMainRegex: (Test)?$
IncludeIsMainSourceRegex: ""
IndentCaseLabels: false
IndentCaseBlocks: false
IndentGotoLabels: true
IndentPPDirectives: None
IndentExternBlock: AfterExternBlock
IndentRequires: false
IndentWidth: 4
IndentWrappedFunctionNames: false
InsertNewlineAtEOF: false
InsertTrailingCommas: None
JavaScriptQuotes: Leave
JavaScriptWrapImports: true
KeepEmptyLinesAtTheStartOfBlocks: true
MacroBlockBegin: ""
MacroBlockEnd: ""
MaxEmptyLinesToKeep: 1
NamespaceIndentation: None
PackConstructorInitializers: Never
PenaltyBreakAssignment: 20
PenaltyBreakBeforeFirstCallParameter: 1000
PenaltyBreakComment: 200
PenaltyBreakFirstLessLess: 125
PenaltyBreakString: 1000
PenaltyBreakTemplateDeclaration: 10
PenaltyExcessCharacter: 10
PenaltyReturnTypeOnItsOwnLine: 60
PenaltyIndentedWhitespace: 0
PointerAlignment: Left
QualifierAlignment: Left
ReflowComments: true
SortIncludes: CaseSensitive
SortJavaStaticImport: Before
SortUsingDeclarations: true
SpaceAfterCStyleCast: false
SpaceAfterLogicalNot: false
SpaceAfterTemplateKeyword: true
SpaceBeforeAssignmentOperators: true
SpaceBeforeCaseColon: false
SpaceBeforeCpp11BracedList: false
SpaceBeforeCtorInitializerColon: true
SpaceBeforeInheritanceColon: true
SpaceBeforeParens: ControlStatements
SpaceAroundPointerQualifiers: Default
SpaceBeforeRangeBasedForLoopColon: true
SpaceInEmptyBlock: false
SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 1
SpacesInAngles: false
SpacesInConditionalStatement: false
SpacesInContainerLiterals: true
SpacesInCStyleCastParentheses: false
SpacesInParentheses: false
SpacesInSquareBrackets: false
SpaceBeforeSquareBrackets: false
StatementAttributeLikeMacros:
- Q_EMIT
Standard: c++17
StatementMacros:
- Q_UNUSED
- QT_REQUIRE_VERSION
TabWidth: 8
UseCRLF: false
UseTab: Never
WhitespaceSensitiveMacros:
- STRINGIZE
- PP_STRINGIZE
- BOOST_PP_STRINGIZE
- NS_SWIFT_NAME
- CF_SWIFT_NAME
8 changes: 4 additions & 4 deletions .github/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ RUN mkdir -p /deps
ARG DEPS_GOOGLETEST_V="1.15.2"
RUN cd /deps \
&& dir="googletest-${DEPS_GOOGLETEST_V}" \
&& curl -sL https://github.com/google/googletest/releases/download/v${DEPS_GOOGLETEST_V}/$dir.tar.gz | tar xzf - \
&& i=0 && while ! curl -sL https://github.com/google/googletest/releases/download/v${DEPS_GOOGLETEST_V}/$dir.tar.gz | tar xzf -; do test "$i" -eq 5 && exit 1; i=$((i+1)); sleep 1; done \
Copy link

Copilot AI Dec 12, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This curl | tar pipeline downloads and extracts the googletest source archive during the CI image build without any checksum or signature verification, creating a supply-chain risk. If an attacker can tamper with the GitHub release asset or intercept the connection, they could deliver a malicious archive whose build system executes arbitrary code in your build environment. Fetch the tarball via HTTPS but also pin and verify its integrity (e.g. by checking a known hash or signature) before extraction and compilation.

Copilot uses AI. Check for mistakes.
&& cmake -B "build/$dir" \
-DCMAKE_BUILD_TYPE=Release \
-DBUILD_SHARED_LIBS=ON \
Expand All @@ -50,7 +50,7 @@ RUN cd /deps \
ARG DEPS_JSON_SCHEMA_VALIDATOR_V="2.3.0"
RUN cd /deps \
&& dir="json-schema-validator-${DEPS_JSON_SCHEMA_VALIDATOR_V}" \
&& curl -sL https://github.com/pboettch/json-schema-validator/archive/refs/tags/${DEPS_JSON_SCHEMA_VALIDATOR_V}.tar.gz | tar xzf - \
&& i=0 && while ! curl -sL https://github.com/pboettch/json-schema-validator/archive/refs/tags/${DEPS_JSON_SCHEMA_VALIDATOR_V}.tar.gz | tar xzf - ; do test "$i" -eq 5 && exit 1; i=$((i+1)); sleep 1; done \
Copy link

Copilot AI Dec 12, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This curl | tar pipeline for json-schema-validator downloads and unpacks a remote archive without any integrity check, which is a supply-chain vulnerability. A compromised GitHub release or network path could provide a malicious tarball whose CMake or build scripts execute arbitrary code during the Docker image build. Add a pinned hash or signature verification step for the downloaded archive and fail the build if the content does not match the expected value.

Copilot uses AI. Check for mistakes.
&& cmake -B "build/$dir" \
-DCMAKE_BUILD_TYPE=Release \
-DBUILD_SHARED_LIBS=ON \
Expand All @@ -63,7 +63,7 @@ RUN cd /deps \
ARG DEPS_WEBSOCKETPP_V="0.8.2"
RUN cd /deps \
&& dir="websocketpp-${DEPS_WEBSOCKETPP_V}" \
&& curl -sL https://github.com/zaphoyd/websocketpp/archive/refs/tags/${DEPS_WEBSOCKETPP_V}.tar.gz | tar xzf - \
&& i=0 && while ! curl -sL https://github.com/zaphoyd/websocketpp/archive/refs/tags/${DEPS_WEBSOCKETPP_V}.tar.gz | tar xzf - ; do test "$i" -eq 5 && exit 1; i=$((i+1)); sleep 1; done \
Copy link

Copilot AI Dec 12, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The curl | tar usage for websocketpp pulls and extracts unverified code from GitHub at build time, exposing the CI build to supply-chain compromise. If the tarball is replaced or tampered with, its contents or build configuration could run arbitrary commands when you subsequently configure and build it. Ensure the archive is pinned to an immutable artifact and that its checksum or signature is validated before extraction and compilation.

Copilot uses AI. Check for mistakes.
&& cmake -B "build/$dir" \
-DCMAKE_BUILD_TYPE=Release \
-DBUILD_SHARED_LIBS=ON \
Expand All @@ -83,7 +83,7 @@ RUN pip install --break-system-packages gcovr
ARG DEPS_TRANSPORT_V
RUN cd /deps \
&& dir="firebolt-native-transport-${DEPS_TRANSPORT_V}" \
&& curl -sL https://github.com/rdkcentral/firebolt-native-transport/releases/download/v${DEPS_TRANSPORT_V}/firebolt-native-transport-${DEPS_TRANSPORT_V}.tar.gz | tar xzf - \
&& i=0 && while ! curl -sL https://github.com/rdkcentral/firebolt-native-transport/releases/download/v${DEPS_TRANSPORT_V}/firebolt-native-transport-${DEPS_TRANSPORT_V}.tar.gz | tar xzf - ; do test "$i" -eq 5 && exit 1; i=$((i+1)); sleep 1; done \
Copy link

Copilot AI Dec 12, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This curl | tar pipeline for firebolt-native-transport downloads and extracts a remote release without verifying its integrity, which is a direct supply-chain risk. An attacker who can alter the release asset or intercept the download could deliver a malicious archive whose build steps execute arbitrary code in your CI environment, potentially accessing secrets or poisoning artifacts. Add integrity verification (e.g. pinned hash or signature check) for the downloaded tarball and fail the build if the content is not exactly what is expected.

Copilot uses AI. Check for mistakes.
&& cmake -B "build/$dir" \
-DCMAKE_BUILD_TYPE=Release \
-DBUILD_SHARED_LIBS=ON \
Expand Down
46 changes: 26 additions & 20 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ name: CI (c++) Build and Test

on:
workflow_dispatch:
# push:
# branches: [ main, next ]
# pull_request:
# branches: [ main, next ]
push:
branches: [ main, next ]
pull_request:
branches: [ main, next ]

defaults:
run:
Expand Down Expand Up @@ -48,7 +48,7 @@ jobs:

- name: Get Transport Version for Build-Arg
id: transport_version
run: echo "version=$(cat ${{ github.workspace }}/src/cpp/.transport.version)" >> $GITHUB_OUTPUT
run: echo "version=$(cat ${{ github.workspace }}/.transport.version)" >> $GITHUB_OUTPUT

- name: Build and push Docker image
uses: docker/build-push-action@v5
Expand Down Expand Up @@ -84,8 +84,8 @@ jobs:
run: |
docker run --rm --user "$(id -u):$(id -g)" -v ${{ github.workspace }}:/workspace ${{ needs.build_docker.outputs.image_tag }} \
bash -c " \
cd ./src/cpp \
&& git ls-files -- '*.cpp' '*.h' | xargs clang-format --dry-run --Werror \
set -e \
&& git ls-files -- '*.cpp' '*.h' | xargs clang-format --dry-run --Werror \
"

build_project:
Expand Down Expand Up @@ -117,7 +117,7 @@ jobs:
run: |
docker run --rm --user "$(id -u):$(id -g)" -v ${{ github.workspace }}:/workspace ${{ needs.build_docker.outputs.image_tag }} \
bash -c " \
cd src/cpp \
set -e \
&& cmake -B build -S . \
-DCMAKE_BUILD_TYPE=Debug \
-DENABLE_TESTS=ON \
Expand All @@ -127,13 +127,16 @@ jobs:
- name: Build Project
run: |
docker run --rm --user "$(id -u):$(id -g)" -v ${{ github.workspace }}:/workspace ${{ needs.build_docker.outputs.image_tag }} \
bash -c "cmake --build src/cpp/build --parallel"
bash -c " \
set -e \
&& cmake --build build --parallel \
"

- name: Upload build directory
uses: actions/upload-artifact@v4
with:
name: build-dir
path: ${{ github.workspace }}/src/cpp/build
path: ${{ github.workspace }}/build

unit_tests:
permissions:
Expand All @@ -156,20 +159,23 @@ jobs:
uses: actions/download-artifact@v4
with:
name: build-dir
path: ${{ github.workspace }}/src/cpp/build
path: ${{ github.workspace }}/build

- name: Run Unit Tests
run: |
chmod +x ${{ github.workspace }}/src/cpp/build/test/FireboltClientUnitTests
chmod +x ${{ github.workspace }}/build/test/FireboltClientUnitTests
docker run --rm --user "$(id -u):$(id -g)" -v ${{ github.workspace }}:/workspace ${{ needs.build_docker.outputs.image_tag }} \
bash -c "ctest --test-dir src/cpp/build/test"
bash -c " \
set -e \
&& ctest --test-dir build/test \
"

- name: Generate Coverage Report
run: |
docker run --rm --user "$(id -u):$(id -g)" -v ${{ github.workspace }}:/workspace ${{ needs.build_docker.outputs.image_tag }} \
bash -c " \
set -e \
&& cd src/cpp/build \
&& cd build \
&& mkdir -p coverage \
&& gcovr -r .. \
--exclude '.*/test/.*\.h' \
Expand All @@ -184,12 +190,12 @@ jobs:
uses: actions/upload-artifact@v4
with:
name: coverage-report
path: ${{ github.workspace }}/src/cpp/build/coverage/
path: ${{ github.workspace }}/build/coverage/

- name: Code Coverage Summary Report
uses: irongut/CodeCoverageSummary@v1.3.0
with:
filename: src/cpp/build/coverage.cobertura.xml
filename: build/coverage.cobertura.xml
badge: true
hide_complexity: true
format: markdown
Expand Down Expand Up @@ -221,7 +227,7 @@ jobs:
uses: actions/download-artifact@v4
with:
name: build-dir
path: ${{ github.workspace }}/src/cpp/build
path: ${{ github.workspace }}/build

- name: Setup Mock-Firebolt
id: setup-mock
Expand All @@ -235,11 +241,11 @@ jobs:

- name: Run Component Tests
run: |
chmod +x ${{ github.workspace }}/src/cpp/build/test/FireboltClientComponentTests
chmod +x ${{ github.workspace }}/build/test/FireboltClientComponentTests
docker run --rm --user "$(id -u):$(id -g)" -v ${{ github.workspace }}:/workspace -v ${{ env.MOCK_PATH }}:/mock ${{ needs.build_docker.outputs.image_tag }} \
./.github/scripts/run-component-tests.sh \
--mock /mock \
--config /workspace/.github/mock-firebolt/config.json \
--openrpc /workspace/src/cpp/firebolt-open-rpc.json \
--openrpc /workspace/firebolt-open-rpc.json \
--app-openrpc /workspace/.github/openrpc/firebolt-app-open-rpc.json \
--test-exe /workspace/src/cpp/build/test/FireboltClientComponentTests
--test-exe /workspace/build/test/FireboltClientComponentTests
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
node_modules/
build/
build-*/
1 change: 1 addition & 0 deletions .transport.version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
1.0.0-next.24
Loading