[ 
https://issues.apache.org/jira/browse/HDDS-11421?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18102342#comment-18102342
 ] 

Chia-Chuan Ho commented on HDDS-11421:
--------------------------------------

Hi [~karn.singh] 
 
The issue is caused by missing DtFetcher registrations for o3 and ofs. Ozone 
currently registers only O3fsDtFetcher for o3fs, so dtutil writes an empty 
credentials file containing only the HDTS header.
 
Proposed fix:
- Add and register fetchers for o3 and ofs.
- Use OFS directly for ofs://.
- Map o3://<OM authority> to ofs://<OM authority> for token retrieval.
- Add unit and secure smoke tests for both schemes.
 
This should be a client-side fix without OM or token-format changes.
 
Please let me know if there are concerns with using the existing OFS path to 
retrieve a token for an o3:// OM authority.
 
Thanks!

> Invalid token generated by "ozone dtutil get" command
> -----------------------------------------------------
>
>                 Key: HDDS-11421
>                 URL: https://issues.apache.org/jira/browse/HDDS-11421
>             Project: Apache Ozone
>          Issue Type: Bug
>          Components: Ozone CLI
>            Reporter: Karn Kumar Singh
>            Priority: Major
>
> The "ozone dtutil get" command generates an invalid token when the o3 or ofs 
> scheme is passed, while it does generate a valid token when passed the hdfs 
> scheme.
> *Repro step:* 
>  # Create a token using the "ozone dtutil get" command and pass the o3 or ofs 
> scheme
> *Log:* 
> {code:java}
> # ozone dtutil get o3://ozone1/ token
> # ozone dtutil print token
> File: token
> # cat token
> HDTS
> # ozone dtutil get ofs://ozone1/ token1
> # ozone dtutil print token1
> File: token1
> # cat token1
> HDTS
> # ozone dtutil get hdfs://ns1 token_hdfs
> 24/09/05 12:58:23 INFO hdfs.DFSClient: Created token for hdfs: 
> HDFS_DELEGATION_TOKEN [email protected], renewer=, realUser=, 
> issueDate=1725541103043, maxDate=1726145903043, sequenceNumber=5, 
> masterKeyId=11 on ha-hdfs:ns1 
> # ozone dtutil print token_hdfs
> File: token_hdfs
> Token kind               Service              Renewer         Exp date     
> URL enc token
> --------------------------------------------------------------------------------
> HDFS_DELEGATION_TOKEN    ha-hdfs:ns1                          9/12/24, 12:58 
> PM **********
> {code}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to