1
0
mirror of https://github.com/FreeRTOS/FreeRTOS-Plus-TCP synced 2025-10-20 22:10:04 +08:00
Commit Graph

23 Commits

Author SHA1 Message Date
tony-josi-aws
de3ffd4d69 [AUTO][RELEASE]: Update version number in source files 2024-12-11 04:15:08 +00:00
Holden
1599660ad3 ARP/ND Build Separation (#1175)
* Separate ARP and ND

* Uncrustify: triggered by comment.

* Fully separate ARP & ND

* Fix tracing and config macros

* Fix Build Issues

* Changed resolution enum name

* Add ND Timer event implementation

* Uncrustify: triggered by comment.

* Fix Tests

* Fix Unit Tests

* Uncrustify: triggered by comment.

* Fix CBMC testing

* Fix ARP utest

* Code review suggestion

* In unit-test, define ipconfigIS_ENABLED to nothing to pass compilation.

* Fix UT coverage.

* Fix buffer access issue in UT.

* Fix spelling

* 100% UT coverage

* Review Fixes

* Fix Unit Tests

* Fix Coverage

* Fix CBMC proof for xCheckRequiresARPResolution

* Fix CBMC proof for xCheckRequiresARPResolution and formatting

* Fix build issue with tools/tcp_utilities/http_client_test.c

---------

Co-authored-by: GitHub Action <action@github.com>
Co-authored-by: tony-josi-aws <tonyjosi@amazon.com>
Co-authored-by: ActoryOu <ousc@amazon.com>
2024-11-11 19:49:38 +05:30
Holden
04a4b5473e Remove xProcessedTCPMessage (#1122)
* Remove xProcessedTCPMessage

* Uncrustify: triggered by comment

---------

Co-authored-by: GitHub Action <action@github.com>
Co-authored-by: Tony Josi <tonyjosi@amazon.com>
2024-03-25 10:51:37 +05:30
Błażej Sowa
c0f5ba0c82 Fix network down up process (#1030)
* Disable DHCP timer when network goes down

* Don't stop checking the Network Timer

* Fix network down when using RA

* Revert "Don't stop checking the Network Timer"

This reverts commit f5d8d98856.

* Add vSetNotAllNetworksUp function

* Fix unit tests

* Update comments

* Store DHCPv4 socket locally for all endpoints

* Add vDHCPStop and vDHCPv6Stop functions

* Fix IP Utils tests

* Fix most of DHCP unit tests

* Fix formatting

* Change vSetNotAllNetworksUp into a more generic vSetAllNetworksUp

* Fix almost all of DHCP unit tests

* Fix formatting

* Add tests for vDHCPStop and vDHCPv6Stop functions

* Fix formatting

* Remove redundant MISRA comment

* Set all fields of xAddress when binding DHCP socket

* Fix unit test coverage of prvCreateDHCPSocket

* Fix DHCP CBMC memory proof

---------

Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
Co-authored-by: Tony Josi <tonyjosi@amazon.com>
2023-10-10 16:22:22 +05:30
Soren Ptak
eed294c0ec CI-CD Updates (#1014)
* Use new version of CI-CD Actions,  checkout@v3 instead of checkout@v2 on all jobs
* Use cSpell spell check, and use ubuntu-20.04 for formatting check
* Add in bot formatting action
2023-09-05 14:31:24 -07:00
ActoryOu
221d8b932d [IPv6] Add Unit Test for FreeRTOS_IP_Timers. (#863)
* Use endpoint's DHCP timer.

* Add test case description

* Remove useless check in MACRO

* Add test cases for xNetworkTimer and xCalculateSleepTime

* vCheckNetworkTimers

* Remove redundant header files

* full coverage

* Code beautify

* Fix spelling
2023-05-17 17:45:22 +08:00
Tony Josi
1f98752059 Adding IPv4/v6 build level separation: integration branch (#855)
* use matching endpoint instead of first endpoint

* update with @htibosch  latest changes

* fix formatting

* fix misra and spellings

* code clean up

* wip separation IP

* separation IP

* separation IP

* wip buils separation

* fixing unit tests

* fix unit tests

* fix formatting

* wip , next prvProcessNetworkDownEvent

* adding build separation to ip utils

* fix unit tests

* fix formatting

* update xCheckRequiresARPResolution

* update vARPAgeCache

* update vARPAgeCache

* misra checks

* fix formatting

* fix misra

* wip s/w: FreeRTOS_recvfrom

* wip sockets till prvSocketBindAdd

* adding  build separation to FreeRTOS_Sockets.c

* add build config support to FreeRTOS_inet_pton FreeRTOS_inet_ntop FreeRTOS_GetIPType

* adding build config support

* fix build  issues

* check misra

* minor fix

* fix unit tests

* fix unit tests build

* Uncrustify: triggered by comment

* fix formatting

* build separate FreeRTOS_TCP_IP.c

* build separate FreeRTOS_TCP_Reception.c

* misra fix

* build separate FreeRTOS_TCP_State_Handling.c

* build separate FreeRTOS_TCP_Transmission.c

* build separate FreeRTOS_TCP_Transmission.c fix build

* adding build separation for FreeRTOS_TCP_Utils.c and FreeRTOS_TCP_Transmission.c

* fix formatting

* UDP: Build Separation Changes

Changes in UDP files to support IPv4 and IPv6 Build Separation.

* fix IPv4 build issues post build sep merge

* IPv4 only build

* more - fix IPv4 build issues post build sep merge

* fix DHCP v4

* fix v6 build

* add v6 build checks

* separate v4v6 tcp files

* fix rebase conflicts

* fix formatting

* fix build when TCP disabled

* add more build checks

* adding more ipv4 flags to v4 specific files

* fix udp unit tests

* add build config build tests to CI

* fix formatting

* fix build checks yml

* DNS: Build Separation Changes

Changes for supporting IPv4 and IPv6 build separation in DNS.

* Routing: Build Separtion Changes

Changes for supporting IPv4 and IPv6 build separation in Routing.

* DNS build fix and rebase to latest changes

* fix formatting

* fix unit tests

* fix formatting

* fix MISRA

* updaating ARP functions to be available on all configs

* plus_tcp_demo_cli build config changes

* fix formatting, guard FreeRTOS_FillEndPoint inside ipconfigUSE_IPv4 check

* more build sepration changes to routing

* build separation plus_tcp_demo_cli.c

* fixing issues with routing, fix formatting

* adding pxFindEndpoint of plus_tcp_demo_cli inside ipconfigUSE_IPv6 != 0 check

* minor build fix

* moving usDNSType of endpoint struct out of ipconfigUSE_IPv6 check

* update code to use IP family while using socket APIs

* moving vSetMultiCastIPv4MacAddress to FreeRTOS_IPv4_Utils.c

* fix routing

* build DNS only if IPv4 is enabled

* fix review feedback

* fix build

* fix build

* fix formatting

* fix comment

* fix wrt reeview feedback

* fix unit tests

* cleanup FreeRTOS_MatchingEndpoint

* fix FreeRTOS_MatchingEndpoint to handle cusstom frames

---------

Co-authored-by: GitHub Action <action@github.com>
Co-authored-by: shubnil <103672514+shubnil@users.noreply.github.com>
2023-05-09 19:48:59 +05:30
Kody Stribrny
f15537303c Fix Clang warnings (#809)
Corrects several warnings from Clang flags
for Clang 13.

Inspired by @phelter's bug report
https://github.com/FreeRTOS/FreeRTOS-Plus-TCP/issues/558
2023-04-18 11:00:00 +00:00
Monika Singh
9a955f27ac Add changes for Coverity fix (#729)
* Fix Coverity issues

* Fix Misra 4.4 violation:The comment resembles a code snippet

* Misra: Rule 10.4 violations

* Misra: Rule 11.8 violations

* Misra: Rule 12.1 violations

* Misra: Rule 8.2, 8.4, 8.5, and 8.9 violations

* Misra: Rule 5.3, 5.8, 21.1 and 21.2  violations

* Misra: Rule 5.7 violations

* Misra: Rule 8.3 violations

* Misra: Rule Reverse NULL violations

* Misra: Rule 10.3, 10.8 and 8.13 violations

* Fix 11.3 and suppress 11.4

* Misra: Rule 14.3, 15.7, 17.2 and 17.7 violations

* Misra: Rule 2.2 and 2.7 violation

* Misra: Rule 21.6, 8.5 and 8.13 violation

* Fix UT compilation

* Update comments

* Fix Spell checker

* Update snprintf
2023-02-28 12:55:20 +05:30
Tony Josi
0e9628796c Fixing doxygen comments (#728)
* updating doxygen config

* fixing doxygen comments

* adding IPv6 files and fixing comments

* fix doxygen cfg and file names in comments

* wip doxygen v6 docs

* adding doxygen comments

* include RA src file to doxgendocs generation

* fix spell check issues

* Uncrustify: triggered by comment.

* fix minor build issue

* fix spell check issues

* Uncrustify: triggered by comment

* fix trailing white space

* Dev integration hein.v8 (#738)

* Updating tcp utilities

* Some more change in dev_integration_hein.v8

* In FreeRTOS_DNS_Parser.c : use 'ipUDP_PAYLOAD_OFFSET_IPv4' in stead of 'ipIP_PAYLOAD_OFFSET'

* And a few more corrections

* Changes to WinPCap network interface, removed debugging code

* After applying uncrustify

* Oops, I forgot the push changes in include files.

* Now removing it, hopefully

---------

Co-authored-by: Nikhil Kamath <110539926+amazonKamath@users.noreply.github.com>
Co-authored-by: Monika Singh <108652024+moninom1@users.noreply.github.com>

* Fix CBMC proofs for DNS (#718)

* Use CBMC XML output to enable VSCode debugger (#673)

Prior to this commit, CBMC would emit logging information in plain text
format, which does not contain information required for the CBMC VSCode
debugger. This commit makes CBMC use XML instead of plain text.

Co-authored-by: Mark Tuttle <tuttle@acm.org>

* wip

* wip DNSgetHostByName

* wip DNSgetHostByName

* fixed cbmc proof for DNS_ReadNameField

* wip DNSgetHostByName_a_harness

* Fix CBMC prooff for DNSgetHostByName

* wip fix DNSgetHostByName_a CBMC proof

* fixed cbmc target func not called issue in DNSclear

* fixed cbmc target func not called issue in DNSlookup

* fix DNSgetHostByName_a CBMC proof

* update comments

* more asserts

* fixing formatting

* updating as per review comments

* fix dns after review comments

* adding more asserts

* adds more asserts

* minor fix

* fixing comments

* fixing comments

* fixing minor issue

* fixing DNS_ReadReply() signature

* making code more consistant

* adding more  asserts

* making code more consistent

---------

Co-authored-by: Kareem Khazem <karkhaz@amazon.com>
Co-authored-by: Mark Tuttle <tuttle@acm.org>

* Uncrustify: triggered by comment

* fixing formatting

---------

Co-authored-by: GitHub Action <action@github.com>
Co-authored-by: Hein Tibosch <hein_tibosch@yahoo.es>
Co-authored-by: Nikhil Kamath <110539926+amazonKamath@users.noreply.github.com>
Co-authored-by: Monika Singh <108652024+moninom1@users.noreply.github.com>
Co-authored-by: Kareem Khazem <karkhaz@amazon.com>
Co-authored-by: Mark Tuttle <tuttle@acm.org>
2023-02-24 13:58:53 +05:30
Hein Tibosch
f88dea60ca Reparations and recommendations for the dev/IPv6_integration branch (#664)
* Reparations and recommendations for the dev/IPv6_integration branch
* Applied uncrustify
* More changes after testing ARP, ICMP4, ICMP6, UDPv4 and UDPv6, DNSv6
* A few changes to DNS after testing it
2023-01-25 18:33:44 +05:30
Tony Josi
575425866e Fixes the build issue with unit tests for IP timers (#603)
* WIP Fix build for IP ttimers

* Fixed build for IP timers

* removed global config settings specific to ip timers test

* Updating the branch with latestt target branch changes

* Uncrustify: triggered by comment.

Co-authored-by: GitHub Action <action@github.com>
2022-12-22 12:43:54 +05:30
xuelix
f29870920d Fixing MISRA violation for FreeRTOS_IP*, FreeRTOS_DHCP* (#604)
* Fixing MISRA violation for FreeRTOS_IP*, FreeRTOS_DHCP*
* remove temp change
2022-12-14 09:19:08 +05:30
Monika Singh
1d3f1a4e88 Add endpoint changes to DHCP files (#593)
* DHCP.c changes and compilation fix
* Update end point changes
* Run uncrustify
2022-12-08 11:30:24 +05:30
Monika Singh
96643cedf1 Add IPv6 data path and endpoint changes to FreeRTOS_IP.c (#591)
* Add IPv6 data path and endpoint changes to FreeRTOS_IP.c
* Add FreeRTOS_IPv4.h and FreeRTOS_IPv6.h files.
* Fix compilation issues and run Uncrustify
2022-12-06 11:59:32 +05:30
xuelix
4a453b5495 Fix compilation errors and misra violations (#594)
* Fix compilation errors and misra violations

* Fix compilation error
2022-12-02 17:20:46 +05:30
Monika Singh
70c261d986 Add IPv6 changes to FreeRTOS_IP_Timer FreeRTOS_IP_Utils file. (#572)
- Add IPv6 changes to FreeRTOS_IP_Timer FreeRTOS_IP_Utils
- Add FreeRTOS_DHCPv6.h
- Update generateChecksum.
- MISRA: Fix rule 1.1, 8.13, 8.5, 20.9 and Suppress rule 8.9, 11.3
- Limit the use of ipconfigUSE_IPV6
- Run uncrustify and update the files
2022-11-21 14:22:29 +05:30
Hein Tibosch
188a9d02f4 IPv4/single: connect() should return immediately after a protocol error and other things (#559)
* IPv4/single: Let connect() return as soon as socket gets closed

* Let both connect() and accept() return after a 'eSOCKET_CLOSED' event

* Included hang protection of orphaned socket from PR #545

* Lexicon.txt change

* Remove a variable that was not used

* Update source/FreeRTOS_Sockets.c

Co-authored-by: Aniruddha Kanhere <60444055+AniruddhaKanhere@users.noreply.github.com>

* Update source/FreeRTOS_TCP_IP.c

Co-authored-by: Aniruddha Kanhere <60444055+AniruddhaKanhere@users.noreply.github.com>

* moved declaration to beginning of block

* Update source/FreeRTOS_TCP_IP.c

Co-authored-by: Aniruddha Kanhere <60444055+AniruddhaKanhere@users.noreply.github.com>

* Uncrustify: triggered by comment.

* Fix unit test expectations

* Avoid a recursive call to vTCPStateChange()

* Uncrustify: triggered by comment.

* Fix CBMC proof assumptions

* Get unit-test coverage up

* Fix timers unit-tests

* Socket unit-test for closed socket

* Fix a unit-test expectations

* Fix spell check

* Uncrustify: triggered by comment.

* Using debug_printf in stead of printf for logging.

* Use debug printf instead of printf in 2 locations

Co-authored-by: Hein Tibosch <hein@htibosch.net>
Co-authored-by: Aniruddha Kanhere <60444055+AniruddhaKanhere@users.noreply.github.com>
Co-authored-by: GitHub Action <action@github.com>
2022-10-11 14:20:13 -07:00
Aniruddha Kanhere
1ab6eb8885 Update version numbers and licensing info (#541)
* Update source location for coverity

* Add coverage checker

* Add build check with default configuration

* Fix build combination and DNS error

* uncrustified and fixed cmakelists

* This commit updates version number in all files to Development-Branch

* Update version number macros

* This commit fixes a typo in version number macro

* Added a 'critical section' to prevent a race condition in stream buffers

* Uncrustify: triggered by comment.

* Fixed unit-tests by adding mocked functions

* Initial commit of file README.md

* Update README.md

* Fix the title of README file in coverity

* Addressed issue comments

* Update command

* Add details about remaining exception

* Move file to original location

* Remove use of sudo in commands

* Fix links; added coverity version note

* Update README.md

* Remove CMake installation instructions

* Update manifest/history and copyright year

* Update kernel version to 10.4.5

* Update remaining copyright year instances

* Update the version number macros

* Update license header titles

* Remove kernel license header and add TCP header

Co-authored-by: GitHub Action <action@github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2022-08-12 16:21:44 -07:00
Aniruddha Kanhere
f44d36d5ce Update version number of TCP to development (#516)
* Update source location for coverity

* Add coverage checker

* Add build check with default configuration

* Fix build combination and DNS error

* uncrustified and fixed cmakelists

* This commit updates version number in all files to Development-Branch

* Update version number macros

* This commit fixes a typo in version number macro
2022-07-06 10:29:48 -07:00
Hein Tibosch
2b99a0cb3e Let the TCP timer becomes expired in stead of active (#481)
* Let the TCP timer becomes expired in stead of active

* Renamed parameter of function vIPSetTCPTimerExpiredState

* Adapt unit tests to use the new name and field

* Change bActive to bExpired

* Empty commit

* Fix spell check

Co-authored-by: Hein Tibosch <hein@htibosch.net>
Co-authored-by: Aniruddha Kanhere <60444055+AniruddhaKanhere@users.noreply.github.com>
2022-06-13 15:27:39 -07:00
xuelix
4fb9674de0 Misra check fix and update (#476)
* Misra check fix and update
2022-06-06 17:47:09 -07:00
Aniruddha Kanhere
a4124602cc Merge changes to main.
This commit brings in the refactoring and restructuring changes
from IntegrationTesting1 branch to the main branch.
It also includes additional unit tests for 100% coverage.
The rationale behind not creating a PR is that the conflicts were too
huge to be resolved correctly. Thus, a force push to the main branch is
being done.
2022-05-26 12:42:45 -07:00