Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TACACS] Ignore TACACS accounting trace log when debug disabled. #16482

Merged
merged 3 commits into from
Jan 23, 2024

Conversation

liuh-80
Copy link
Contributor

@liuh-80 liuh-80 commented Sep 7, 2023

Ignore TACACS accounting trace log when debug disabled.

Why I did it

TACACS accounting trace log is only for debug, improve code to not generate trace log when debug disabled.

Work item tracking
  • Microsoft ADO: 25270078

How I did it

Ignore TACACS accounting trace log when debug disabled.

How to verify it

Pass all UT.
Manually verified the auditd-tacplus not generate trace log when debug disabled.

Which release branch to backport (provide reason below if selected)

  • 201811
  • 201911
  • 202006
  • 202012
  • 202106
  • 202111
  • 202205
  • 202211
  • 202305

Tested branch (Please provide the tested image version)

will updated with this PR image later.

  • SONiC.master-16482.360728-2c8b4066f
  • SONiC.202205-16653.368721-c45a92ff2
  • SONiC.202305-19061.554667-4e17fde97
  • SONiC.202311-19060.554666-5dc06ca6c

Description for the changelog

Ignore TACACS accounting trace log when debug disabled.

Link to config_db schema for YANG module changes

A picture of a cute animal (not mandatory but encouraged)

@liuh-80
Copy link
Contributor Author

liuh-80 commented Sep 12, 2023

re-trigger build by close and re-open

@liuh-80 liuh-80 closed this Sep 12, 2023
@liuh-80 liuh-80 reopened this Sep 12, 2023
@liuh-80 liuh-80 marked this pull request as ready for review September 13, 2023 06:10
@liuh-80 liuh-80 requested a review from qiluo-msft September 13, 2023 06:10
@lguohan lguohan added the auth label Sep 23, 2023
@liuh-80 liuh-80 closed this Sep 26, 2023
@liuh-80
Copy link
Contributor Author

liuh-80 commented Sep 28, 2023

Close by mistake, re-open

@liuh-80 liuh-80 reopened this Sep 28, 2023
@qiluo-msft qiluo-msft merged commit a2e57d8 into sonic-net:master Jan 23, 2024
qiluo-msft pushed a commit that referenced this pull request Mar 21, 2024
Fix TACACS local accounting disabled when debug flag disabled.

#### Why I did it
TACACS local accounting use trace() method to output local accounting log, following PR disable trace log when debug flag disabled, 
#16482

Because test case issue, this regression not found. the issue only exists on master branch.

### How I did it
Fix TACACS local accounting disabled when debug flag disabled.

#### How to verify it
Pass all UT.
Fix TACACS accounting UT to prevent regression.

### Tested branch (Please provide the tested image version)

- [] SONiC.master-16482.360728-2c8b4066f

#### Description for the changelog
Fix TACACS local accounting disabled when debug flag disabled.
@liuh-80
Copy link
Contributor Author

liuh-80 commented May 9, 2024

There is a bug in this PR, when backport, the fix PR also need backport: #18357

liuh-80 added a commit to liuh-80/sonic-buildimage that referenced this pull request May 24, 2024
…ic-net#16482)

Ignore TACACS accounting trace log when debug disabled.

#### Why I did it
TACACS accounting trace log is only for debug, improve code to not generate trace log when debug disabled.

##### Work item tracking
- Microsoft ADO: 25270078

#### How I did it
Ignore TACACS accounting trace log when debug disabled.

#### How to verify it
Pass all UT.
Manually verified the auditd-tacplus not generate trace log when debug disabled. 

### Description for the changelog
Ignore TACACS accounting trace log when debug disabled.
liuh-80 added a commit to liuh-80/sonic-buildimage that referenced this pull request May 24, 2024
Fix TACACS local accounting disabled when debug flag disabled.

#### Why I did it
TACACS local accounting use trace() method to output local accounting log, following PR disable trace log when debug flag disabled, 
sonic-net#16482

Because test case issue, this regression not found. the issue only exists on master branch.

### How I did it
Fix TACACS local accounting disabled when debug flag disabled.

#### How to verify it
Pass all UT.
Fix TACACS accounting UT to prevent regression.

### Tested branch (Please provide the tested image version)

- [] SONiC.master-16482.360728-2c8b4066f

#### Description for the changelog
Fix TACACS local accounting disabled when debug flag disabled.
liuh-80 added a commit to liuh-80/sonic-buildimage that referenced this pull request May 24, 2024
…ic-net#16482)

Ignore TACACS accounting trace log when debug disabled.

#### Why I did it
TACACS accounting trace log is only for debug, improve code to not generate trace log when debug disabled.

##### Work item tracking
- Microsoft ADO: 25270078

#### How I did it
Ignore TACACS accounting trace log when debug disabled.

#### How to verify it
Pass all UT.
Manually verified the auditd-tacplus not generate trace log when debug disabled. 

### Description for the changelog
Ignore TACACS accounting trace log when debug disabled.
liuh-80 added a commit to liuh-80/sonic-buildimage that referenced this pull request May 24, 2024
Fix TACACS local accounting disabled when debug flag disabled.

#### Why I did it
TACACS local accounting use trace() method to output local accounting log, following PR disable trace log when debug flag disabled, 
sonic-net#16482

Because test case issue, this regression not found. the issue only exists on master branch.

### How I did it
Fix TACACS local accounting disabled when debug flag disabled.

#### How to verify it
Pass all UT.
Fix TACACS accounting UT to prevent regression.

### Tested branch (Please provide the tested image version)

- [] SONiC.master-16482.360728-2c8b4066f

#### Description for the changelog
Fix TACACS local accounting disabled when debug flag disabled.
@liuh-80
Copy link
Contributor Author

liuh-80 commented May 24, 2024

During validation, I found this PR can't auto cherry-pick because this PR has a code bug which fixed by #18357

So manually create 2 cherry-pick PR:
202305: #19061
202311: #19060

yxieca pushed a commit that referenced this pull request May 28, 2024
…d. (#19060)

* [TACACS] Ignore TACACS accounting trace log when debug disabled. (#16482)

Ignore TACACS accounting trace log when debug disabled.

#### Why I did it
TACACS accounting trace log is only for debug, improve code to not generate trace log when debug disabled.

##### Work item tracking
- Microsoft ADO: 25270078

#### How I did it
Ignore TACACS accounting trace log when debug disabled.

#### How to verify it
Pass all UT.
Manually verified the auditd-tacplus not generate trace log when debug disabled. 

### Description for the changelog
Ignore TACACS accounting trace log when debug disabled.

* Fix tacacs local accounting break. (#18357)

Fix TACACS local accounting disabled when debug flag disabled.

#### Why I did it
TACACS local accounting use trace() method to output local accounting log, following PR disable trace log when debug flag disabled, 
#16482

Because test case issue, this regression not found. the issue only exists on master branch.

### How I did it
Fix TACACS local accounting disabled when debug flag disabled.

#### How to verify it
Pass all UT.
Fix TACACS accounting UT to prevent regression.

### Tested branch (Please provide the tested image version)

- [] SONiC.master-16482.360728-2c8b4066f

#### Description for the changelog
Fix TACACS local accounting disabled when debug flag disabled.
StormLiangMS pushed a commit that referenced this pull request May 31, 2024
…d. (#19061)

Why I did it
TACACS accounting trace log is only for debug, improve code to not generate trace log when debug disabled.

Manually cherry-pick following 2 PR, because fir PR has a code bug, PR validation will block it:
#16482
#18357

Work item tracking
Microsoft ADO: 25270078
How I did it
Ignore TACACS accounting trace log when debug disabled.

How to verify it
Pass all UT.
Manually verified the auditd-tacplus not generate trace log when debug disabled.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants