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

Support url safe base64 #2337

Merged
merged 3 commits into from
Oct 25, 2023
Merged

Support url safe base64 #2337

merged 3 commits into from
Oct 25, 2023

Conversation

chenBright
Copy link
Contributor

@chenBright chenBright commented Aug 1, 2023

What problem does this PR solve?

Issue Number:

Problem Summary:

目前有将url参数进行base64编码的需求,需要bRPC支持url safe base64。

What is changed and the side effects?

Changed:

引入chromium base64url(为适配bRPC,存在少量改动),参考:

Side effects:

  • Performance effects(性能影响):

  • Breaking backward compatibility(向后兼容性):


Check List:

  • Please make sure your changes are compilable(请确保你的更改可以通过编译).
  • When providing us with a new feature, it is best to add related tests(如果你向我们增加一个新的功能, 请添加相关测试).
  • Please follow Contributor Covenant Code of Conduct.(请遵循贡献者准则).

@wasphin
Copy link
Member

wasphin commented Aug 1, 2023

这里更新下 license 说明

brpc/LICENSE

Line 763 in 4615906

src/butil/base64.*

并修改下 ci 豁免相关文件的检查吧

- 'src/butil/base64.*'

chromium-base 下 license 文件没有,这里有个 https://chromium.googlesource.com/chromium/src/+/refs/heads/main/LICENSE
但 copyright 年份和我们列的不一样,这个不确定怎么处理下。

LICENSE Outdated
@@ -897,7 +898,7 @@ Some portions of these files are derived from code in the Chromium project,
copyright (c) Google inc and (c) The Chromium Authors and licensed under the
3-clause BSD license:

Copyright (c) 2000 - 2014 The Chromium Authors. All rights reserved.
Copyright (c) 2000 - 2015 The Chromium Authors. All rights reserved.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

是不是更新这里的copyright 年份就可以?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

我理解这个还不是年份的覆盖,应该需要明确哪些是 2015 哪些是 2000 - 2014。

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

不太懂要怎么处理。
base64url的几个文件内有声明Copyright 2015。
我看butil下属于The Chromium Authors的文件有多个年份的。

Copy link
Member

@wasphin wasphin Aug 3, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

我觉得后面可能得整体再检查一次 copyright 信息,copyright 信息除了有原文件作者授权外不能改,之前邮件讨论过一次。

https://issues.apache.org/jira/browse/LEGAL-645

You are never allowed to change somebody else's Copyright statement without the owner's permission.

有疑问可以在邮件列表再问问看。

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok,已单独指明2015的license

@zyearn
Copy link
Member

zyearn commented Aug 6, 2023

这个库一定要在brpc层引入么,可以在应用层作为一个third party引入么?

@chenBright
Copy link
Contributor Author

可以是可以,base64url是基于base64封装的。但是这样的话,每个有需求的用户都要自己引入了。

@wwbmmm
Copy link
Contributor

wwbmmm commented Aug 10, 2023

LGTM

@wwbmmm wwbmmm merged commit ded7c22 into apache:master Oct 25, 2023
@chenBright chenBright deleted the base64url branch October 25, 2023 07:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants