[openssh] Export remote address to environment variable for TACACS authorization.#12447
Merged
liuh-80 merged 7 commits intosonic-net:masterfrom Nov 3, 2022
Merged
Conversation
This was referenced Oct 19, 2022
Contributor
Author
|
This PR depends on #12327 to merge first. The following packages have unmet dependencies: |
qiluo-msft
reviewed
Oct 21, 2022
src/openssh/patch/0002-Save-remote-address-to-environment-variable-for-TACA.patch
Outdated
Show resolved
Hide resolved
qiluo-msft
reviewed
Oct 21, 2022
src/openssh/patch/0002-Save-remote-address-to-environment-variable-for-TACA.patch
Outdated
Show resolved
Hide resolved
qiluo-msft
reviewed
Oct 21, 2022
src/openssh/patch/0002-Save-remote-address-to-environment-variable-for-TACA.patch
Outdated
Show resolved
Hide resolved
qiluo-msft
reviewed
Oct 21, 2022
src/openssh/patch/0002-Save-remote-address-to-environment-variable-for-TACA.patch
Outdated
Show resolved
Hide resolved
liuh-80
added a commit
that referenced
this pull request
Oct 24, 2022
…12327) Update openssh make file, add missing dependency to libnl. #### Why I did it Openssh indirectly depends on libnl. Another PR #12447 need add new patch to openssh, after adding new patch to openssh, PR build failed with libnl missing error. #### How I did it Update openssh make file, add missing dependency to libnl. #### How to verify it Pass all test case #### Which release branch to backport (provide reason below if selected) <!-- - Note we only backport fixes to a release branch, *not* features! - Please also provide a reason for the backporting below. - e.g. - [x] 202006 --> - [ ] 201811 - [ ] 201911 - [ ] 202006 - [ ] 202012 - [ ] 202106 - [ ] 202111 - [ ] 202205 #### Description for the changelog Update openssh make file, add missing dependency to libnl. #### Ensure to add label/tag for the feature raised. example - PR#2174 under sonic-utilities repo. where, Generic Config and Update feature has been labelled as GCU. #### Link to config_db schema for YANG module changes <!-- Provide a link to config_db schema for the table for which YANG model is defined Link should point to correct section on https://github.com/Azure/sonic-buildimage/blob/master/src/sonic-yang-models/doc/Configuration.md --> #### A picture of a cute animal (not mandatory but encouraged)
Contributor
Author
|
/azp run Azure.sonic-buildimage |
|
Azure Pipelines successfully started running 1 pipeline(s). |
Contributor
Author
|
/azp run Azure.sonic-buildimage |
|
Azure Pipelines successfully started running 1 pipeline(s). |
Contributor
Author
|
/azp run Azure.sonic-buildimage |
|
Azure Pipelines successfully started running 1 pipeline(s). |
qiluo-msft
reviewed
Oct 24, 2022
src/openssh/patch/0002-Export-remote-info-for-authorization.patch
Outdated
Show resolved
Hide resolved
yxieca
pushed a commit
that referenced
this pull request
Oct 27, 2022
…12327) Update openssh make file, add missing dependency to libnl. #### Why I did it Openssh indirectly depends on libnl. Another PR #12447 need add new patch to openssh, after adding new patch to openssh, PR build failed with libnl missing error. #### How I did it Update openssh make file, add missing dependency to libnl. #### How to verify it Pass all test case #### Which release branch to backport (provide reason below if selected) <!-- - Note we only backport fixes to a release branch, *not* features! - Please also provide a reason for the backporting below. - e.g. - [x] 202006 --> - [ ] 201811 - [ ] 201911 - [ ] 202006 - [ ] 202012 - [ ] 202106 - [ ] 202111 - [ ] 202205 #### Description for the changelog Update openssh make file, add missing dependency to libnl. #### Ensure to add label/tag for the feature raised. example - PR#2174 under sonic-utilities repo. where, Generic Config and Update feature has been labelled as GCU. #### Link to config_db schema for YANG module changes <!-- Provide a link to config_db schema for the table for which YANG model is defined Link should point to correct section on https://github.com/Azure/sonic-buildimage/blob/master/src/sonic-yang-models/doc/Configuration.md --> #### A picture of a cute animal (not mandatory but encouraged)
qiluo-msft
reviewed
Oct 28, 2022
| +{ | ||
| + const char *remote_ip = ssh_remote_ipaddr(ssh); | ||
| + const int remote_port = ssh_remote_port(ssh); | ||
| + const char remote_addr_port[32 + INET6_ADDRSTRLEN]; |
Collaborator
Contributor
Author
There was a problem hiding this comment.
It's not necessary: IP port max value is 65535, so '32 + INET6_ADDRSTRLEN' is enough.
qiluo-msft
approved these changes
Oct 31, 2022
Collaborator
|
Please resolve the conflict. |
Merged
7 tasks
Contributor
Author
|
/azp run Azure.sonic-buildimage |
|
Azure Pipelines successfully started running 1 pipeline(s). |
yxieca
pushed a commit
that referenced
this pull request
Nov 10, 2022
…thorization. (#12447) Export remote address to environment variable for TACACS authorization. #### Why I did it When remote user login, nss-tacplus need user remove address for TACACSS authorization. #### How I did it Export remote address to environment variable "SSH_REMOTE_IP" #### How to verify it Pass all E2E test. #### Which release branch to backport (provide reason below if selected) <!-- - Note we only backport fixes to a release branch, *not* features! - Please also provide a reason for the backporting below. - e.g. - [x] 202006 --> - [ ] 201811 - [ ] 201911 - [ ] 202006 - [ ] 202012 - [ ] 202106 - [ ] 202111 - [ ] 202205 #### Description for the changelog Export remote address to environment variable for TACACS authorization. #### Ensure to add label/tag for the feature raised. example - PR#2174 under sonic-utilities repo. where, Generic Config and Update feature has been labelled as GCU. #### Link to config_db schema for YANG module changes <!-- Provide a link to config_db schema for the table for which YANG model is defined Link should point to correct section on https://github.com/Azure/sonic-buildimage/blob/master/src/sonic-yang-models/doc/Configuration.md --> #### A picture of a cute animal (not mandatory but encouraged)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Export remote address to environment variable for TACACS authorization.
Why I did it
When remote user login, nss-tacplus need user remove address for TACACSS authorization.
How I did it
Export remote address to environment variable "SSH_REMOTE_IP"
How to verify it
Pass all E2E test.
Which release branch to backport (provide reason below if selected)
Description for the changelog
Export remote address to environment variable for TACACS authorization.
Ensure to add label/tag for the feature raised. example - PR#2174 under sonic-utilities repo. where, Generic Config and Update feature has been labelled as GCU.
Link to config_db schema for YANG module changes
A picture of a cute animal (not mandatory but encouraged)