Skip to content

[POC] feat: add proxy-doip crate — DoIP transport layer (temporary, RDBI/WDBI only)#13

Open
arvindr19 wants to merge 33 commits into
eclipse-opensovd:mainfrom
arvindr19:feat/proxy-doip
Open

[POC] feat: add proxy-doip crate — DoIP transport layer (temporary, RDBI/WDBI only)#13
arvindr19 wants to merge 33 commits into
eclipse-opensovd:mainfrom
arvindr19:feat/proxy-doip

Conversation

@arvindr19
Copy link
Copy Markdown
Contributor

@arvindr19 arvindr19 commented Apr 22, 2026

Summary

Adds the proxy-doip crate: ISO 13400-2 DoIP TCP server, message parsing, session management, and UDS request dispatch.

Depends on: PR #11 (proxy-core)

Changes

  • DoIpMessage: Parse/serialize DoIP frames (version check, payload types, header validation)
  • RoutingActivationRequest / DiagnosticMessage: ISO 13400-2 payload parsers
  • DoIpServer: TCP listener with connection limiting and per-connection async handlers
  • Session: Routing activation state tracking
  • ConnectionHandler: Frame accumulation, UDS message dispatch to DiagHandler, negative response handling. Named constants for all protocol sizes and magic numbers.

Scope

Handles only ReadDataByIdentifier (0x22) and WriteDataByIdentifier (0x2E). Other SIDs return ServiceNotSupported (NRC 0x11).

Checklist

  • I have tested my changes locally
  • I have added or updated documentation
  • I have linked related issues or discussions
  • I have added or updated tests

Related

Notes for Reviewers

This is a temporary transport layer. message.rs, server.rs, session.rs, and lib.rs will be replaced when integrating with eclipse-opensovd/uds2sovd-proxy#4 and follow-up PRs for the DoIP server. handler.rs contains the UDS dispatch logic and is the primary file for review.

…nd workspace setup

Signed-off-by: Arvind Rathod <Arvind.RA.Rathod@bti.bmwgroup.com>
@arvindr19 arvindr19 requested a review from a team as a code owner April 22, 2026 08:18
@arvindr19 arvindr19 marked this pull request as draft April 22, 2026 08:18
@arvindr19 arvindr19 changed the title Feat/proxy doip feat: add proxy-doip crate — DoIP transport layer (temporary, RDBI/WDBI only) Apr 22, 2026
Signed-off-by: Arvind Rathod <Arvind.RA.Rathod@bti.bmwgroup.com>
Signed-off-by: Arvind Rathod <Arvind.RA.Rathod@bti.bmwgroup.com>
Signed-off-by: Arvind Rathod <Arvind.RA.Rathod@bti.bmwgroup.com>
Signed-off-by: Arvind Rathod <Arvind.RA.Rathod@bti.bmwgroup.com>
@arvindr19 arvindr19 marked this pull request as ready for review April 28, 2026 04:53
Signed-off-by: Arvind Rathod <Arvind.RA.Rathod@bti.bmwgroup.com>
Signed-off-by: Arvind Rathod <Arvind.RA.Rathod@bti.bmwgroup.com>
Signed-off-by: Arvind Rathod <Arvind.RA.Rathod@bti.bmwgroup.com>
@arvindr19 arvindr19 force-pushed the feat/proxy-doip branch 2 times, most recently from 7999eff to a124253 Compare May 7, 2026 10:33
@arvindr19 arvindr19 changed the title feat: add proxy-doip crate — DoIP transport layer (temporary, RDBI/WDBI only) [POC] feat: add proxy-doip crate — DoIP transport layer (temporary, RDBI/WDBI only) May 11, 2026
Signed-off-by: Arvind Rathod <Arvind.RA.Rathod@bti.bmwgroup.com>
arvindr19 added 15 commits May 12, 2026 15:05
Signed-off-by: Arvind Rathod <Arvind.RA.Rathod@bti.bmwgroup.com>
Signed-off-by: Arvind Rathod <Arvind.RA.Rathod@bti.bmwgroup.com>
Signed-off-by: Arvind Rathod <Arvind.RA.Rathod@bti.bmwgroup.com>
- Add UdsResponse<'a> wrapper with sid()/is_negative()/nrc() accessors
- is_negative_response/get_nrc delegate to UdsResponse — no more raw byte indexing
- Add ResolvedService { name, params } struct; replace (String, Map) tuple in
  resolve_read_service / resolve_write_service return types
- Split resolve_service_did into build_did_candidates + match_candidate_did
- or_else + match pattern in activate_base_variant (replaces nested if/else)
- Add RwLock doc comment explaining write-reservation intent
- Remove redundant HashSet alongside Vec in candidate dedup
- Add #[cfg(test)] modules to resolve.rs, metadata.rs, response.rs
  (6 + 9 + 12 new unit tests; 63 total in proxy-core)
…BI only)

Signed-off-by: Arvind Rathod <Arvind.RA.Rathod@bti.bmwgroup.com>
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.

1 participant