Skip to content

RDKEMW-4433: local server build option#57

Open
dwolaver wants to merge 38 commits into
developfrom
feature/RDKEMW-4433_local_server_build_option
Open

RDKEMW-4433: local server build option#57
dwolaver wants to merge 38 commits into
developfrom
feature/RDKEMW-4433_local_server_build_option

Conversation

@dwolaver
Copy link
Copy Markdown
Contributor

Provide an option to build/install a local websocket server.

@dwolaver dwolaver requested review from a team May 19, 2025 22:01
@rdkcmf-jenkins
Copy link
Copy Markdown
Contributor

b'## Blackduck scan failure details

Summary: 0 violations, 0 files pending approval, 1 file pending identification.

  • Protex Server Path: /home/blackduck/github/control/57/rdk/components/generic/control

  • Commit: 0b5f26e

Report detail: gist'

@rdkcmf-jenkins
Copy link
Copy Markdown
Contributor

b'## Blackduck scan failure details

Summary: 0 violations, 0 files pending approval, 1 file pending identification.

  • Protex Server Path: /home/blackduck/github/control/57/rdk/components/generic/control

  • Commit: b074ea3

Report detail: gist'

@rdkcmf-jenkins
Copy link
Copy Markdown
Contributor

b'## Blackduck scan failure details

Summary: 0 violations, 0 files pending approval, 1 file pending identification.

  • Protex Server Path: /home/blackduck/github/control/57/rdk/components/generic/control

  • Commit: 6a06eba

Report detail: gist'

@rdkcmf-jenkins
Copy link
Copy Markdown
Contributor

b'## WARNING: A Blackduck scan failure has been waived

A prior failure has been upvoted

  • Upvote reason: OK

  • Commit: 6a06eba
    '

@dwolaver dwolaver marked this pull request as draft April 30, 2026 19:34
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 12 out of 12 changed files in this pull request and generated 5 comments.

Comment thread src/server/ctrlms_ws.cpp
Comment thread src/server/ctrlms_ws.cpp Outdated
Comment thread src/server/ctrlms_ws.cpp
Comment thread src/server/ctrlms_ws.cpp Outdated
Comment thread src/server/ctrlms_ws.cpp Outdated
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 12 out of 12 changed files in this pull request and generated 5 comments.

Comments suppressed due to low confidence (1)

src/server/ctrlms_ws.cpp:179

  • If listener creation fails after the temp TLS cert/key file was generated, the code breaks out without unlinking the temp file. This can leave sensitive cert/key material on disk in /tmp. Make sure to unlink the temp file in this failure path (and any other early-exit paths) when g_ctrlms_ws.cert_valid is true.
      if(!nopoll_conn_is_ok(g_ctrlms_ws.state.nopoll_conn)) {
         XLOGD_ERROR("Listener connection IPv6 NOT ok");
         nopoll_ctx_unref(g_ctrlms_ws.nopoll_ctx);
         g_ctrlms_ws.nopoll_ctx = NULL;
         nopoll_conn_opts_free(g_ctrlms_ws.opts);

Comment thread src/server/ctrlms_ws.cpp
Comment thread src/server/ctrlms_ws.cpp Outdated
Comment thread src/server/ctrlms_ws.cpp
Comment thread src/server/ctrlms_main.c
Comment thread src/server/ctrlms_main.c
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 12 out of 12 changed files in this pull request and generated 5 comments.

Comment thread src/server/ctrlms_ws.cpp
Comment thread src/server/ctrlms_ws.cpp
Comment thread src/server/ctrlms_ws.cpp
Comment thread src/server/ctrlms_ws.cpp Outdated
Comment thread src/server/ctrlms_main.c
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 12 out of 12 changed files in this pull request and generated 2 comments.

Comment thread src/server/ctrlms_ws.cpp Outdated
Comment thread src/server/ctrlms_ws.cpp Outdated
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 12 out of 12 changed files in this pull request and generated 1 comment.

Comments suppressed due to low confidence (1)

src/server/ctrlms_ws.cpp:231

  • Shutdown cleanup calls dlclose(app_handle) before delete app_interface. If app_interface was created by the plugin, its destructor may be in the unloaded module, making delete undefined behavior. Delete/free the interface object first, then dlclose() the plugin handle.
   if(g_ctrlms_ws.app_handle != NULL) {
      dlclose(g_ctrlms_ws.app_handle);
      g_ctrlms_ws.app_handle = NULL;
   }
   if(g_ctrlms_ws.app_interface != NULL) {
      delete g_ctrlms_ws.app_interface;
      g_ctrlms_ws.app_interface = NULL;
   }

Comment thread src/server/ctrlms_ws.cpp Outdated
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 12 out of 12 changed files in this pull request and generated 2 comments.

Comment thread src/server/ctrlms_ws.cpp
Comment thread src/server/ctrlms_ws.cpp Outdated
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 12 out of 12 changed files in this pull request and generated 1 comment.

Comments suppressed due to low confidence (1)

src/server/ctrlms_ws.cpp:558

  • The stub virtual methods leave parameters unused (payload and json_obj). With -Wall -Werror enabled for controlServer, this is likely to produce -Wunused-parameter and break the build. Please explicitly mark these parameters unused (or remove the parameter names in the definitions) to keep the stub compile-clean.
bool ctrlms_app_interface_t::ws_receive_audio(const unsigned char *payload, int payload_size) {
   XLOGD_INFO("STUB: audio received size <%d>", payload_size);
   return(false);
};
bool ctrlms_app_interface_t::ws_receive_json(const json_t *json_obj) {
   XLOGD_INFO("STUB: json object received");
   return(false);

Comment thread src/server/ctrlms_ws.cpp
Copy link
Copy Markdown
Contributor

@egalla204 egalla204 left a comment

Choose a reason for hiding this comment

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

approved for test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants