diff options
| author | Donald Sharp <donaldsharp72@gmail.com> | 2024-11-15 09:21:52 -0500 | 
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-11-15 09:21:52 -0500 | 
| commit | e2314c9169e3e92d955811ed4aa9177d25e6b813 (patch) | |
| tree | 0db557cc8b0f0080a468f50017422cd612a98a79 | |
| parent | 076879a279c59ca389b93d504380506cf388052d (diff) | |
| parent | f765bc4144c0741b5427cc6f61af497170f28484 (diff) | |
Merge pull request #17434 from opensourcerouting/fix/bgp_color_parsing_ecomm
bgpd: Fix color extended community parsing
| -rw-r--r-- | bgpd/bgp_ecommunity.c | 2 | 
1 files changed, 2 insertions, 0 deletions
diff --git a/bgpd/bgp_ecommunity.c b/bgpd/bgp_ecommunity.c index 5935028a59..e794ccb308 100644 --- a/bgpd/bgp_ecommunity.c +++ b/bgpd/bgp_ecommunity.c @@ -766,6 +766,8 @@ static const char *ecommunity_gettoken(const char *str, void *eval_ptr,  				if (*endptr != '\0' || tmp_as > BGP_AS4_MAX ||  				    errno)  					goto error; +				if (*token == ecommunity_token_color && tmp_as > 3) +					goto error;  				as = (as_t)tmp_as;  			}  		} else if (*p == '.') {  | 
