-
Notifications
You must be signed in to change notification settings - Fork 37
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
WiP: support PKCS12 format for keystore #51
Conversation
add load function add new dependency 'github.com/corbym/gocrest' for testing add new dependency 'software.sslmate.com/src/go-pkcs12' for PKCS12 support
refactor tests for better readability
Hi @nitram509 Thank you for your work on this feature, and for keeping me in the loop before it is finalized. I appreciate the time and effort you've been investing. Regarding tests, while I generally prefer using github.com/stretchr/testify, for this project I've decided to stick with the standard library approach to reduce the number of third-party dependencies to the minimum. Let's maintain consistency across the project's tests by continuing to use the stdlib approach for both existing and new tests. Great work! Looking forward to completing the implementation 🚀 |
P.S. I think we will release this feature as a new major version. So, if you need new Go features like generics or anything else, feel free to upgrade the Go version in go.mod to the previous major release (1.22). https://endoflife.date/go |
@pavlo-v-chernykh may I reflect one thought: One more thing I found out yesterday ... and a related question: |
If you are eager to port all existing tests to Testify, let’s do it. P.S. In my previous comment, I explained my reasoning regarding dependencies when starting the project back in 2016, before Go modules existed. At that time, Testify was fresh and new and the only dependency I wanted to use. So, I decided to go without it to simplify usage for users. While that is no longer the case, I still prefer to minimize the number of dependencies. P.S. I understand that test dependencies do not affect the production build, only the time required to download dependencies on CI/CD if users do not use vendoring.
Could you elaborate on this? I think I did not fully understand your point. My guess is that the go-pkcs12 library still do not support all the functionality required to be on par with Java implementation and support all the use cases to be compatible with jdk keytool. Am I right? |
Indeed. What I found, that reading p12 files with and without a password works with go-pkcs12 lib. |
I got it. Could you check, would it be possible to use the code from pkcs12.go#L152 or an Encoder implementation to implement behavior compatible with JDK?
|
@pavlo-v-chernykh the Hacktoberfest is starting soon, and it would be cool to contribute. |
@nitram509 hi, TLDR:
Just to let you know, for your pull requests to count towards Hacktoberfest, they need to be created and merged between October 1 and October 31. So your current PR doesn’t count toward the event. See AFAIU the PR labeled with To manage expectations, I will create tasks that describe the requirements and acceptance criteria for decoder and encoder separately. |
The ticket for decoder #52 Please read the description, and let’s discuss any unclear points if required. |
I will close this one, as it seems simpler to me, with latest changes merged. |
This is a DRAFT PR, and any feedback is welcome.
I will change the title, and drop the 'WiP' once it's ready for review ... just wanted to be transparent during development.
Relates to issue #47
Technical notes: