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

Problem: ssl fields on remote are hard to use #99

Merged
merged 1 commit into from Apr 26, 2019
Merged

Conversation

@dkliban
Copy link
Member

dkliban commented Apr 24, 2019

Solution: switch all ssl fields to TextField

This patch switches the storage of SSL certs, keys, and CAs from filesystem to
database. This patch also introduces a new serializer field that returns a SHA256
digest for GET operations.

Required PR: pulp/pulpcore-plugin#91

Fixes: #4506
https://pulp.plan.io/issues/4506

Re: #4676
https://pulp.plan.io/issues/4676

@dkliban dkliban force-pushed the dkliban:ssl-fields branch 3 times, most recently from c9e004b to fc80217 Apr 24, 2019
@codecov

This comment has been minimized.

Copy link

codecov bot commented Apr 24, 2019

Codecov Report

Merging #99 into master will increase coverage by 0.01%.
The diff coverage is 90%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master     #99      +/-   ##
=========================================
+ Coverage   67.79%   67.8%   +0.01%     
=========================================
  Files          65      65              
  Lines        3018    3019       +1     
=========================================
+ Hits         2046    2047       +1     
  Misses        972     972
Impacted Files Coverage Δ
pulpcore/app/serializers/__init__.py 100% <ø> (ø) ⬆️
pulpcore/app/serializers/repository.py 98.97% <100%> (ø) ⬆️
pulpcore/app/models/repository.py 64.51% <100%> (-0.04%) ⬇️
pulpcore/app/serializers/fields.py 67.53% <75%> (+0.4%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 31bda7b...0fea20f. Read the comment docs.

@dkliban dkliban force-pushed the dkliban:ssl-fields branch from fc80217 to b0fd3a5 Apr 26, 2019
Solution: switch all ssl fields to TextField

This patch switches the storage of SSL certs, keys, and CAs from filesystem to
database. This patch also introduces a new serializer field that returns a SHA256
digest for GET operations.

Required PR: pulp/pulpcore-plugin#91

fixes: #4506
https://pulp.plan.io/issues/4506

re: #4676
https://pulp.plan.io/issues/4676
@dkliban dkliban force-pushed the dkliban:ssl-fields branch from b0fd3a5 to 0fea20f Apr 26, 2019
@@ -1,5 +1,6 @@
from gettext import gettext as _
import os
import hashlib

This comment has been minimized.

Copy link
@bmbouter

bmbouter Apr 26, 2019

Member

alphebatize this please.

@@ -209,3 +210,14 @@ def to_representation(self, value):
prefix.strip('/'),
base_path.lstrip('/')
))


class SecretCharField(serializers.CharField):

This comment has been minimized.

Copy link
@bmbouter
Copy link
Member

bmbouter left a comment

This is a great improvement! Thank you @dkliban 👍

@dkliban dkliban merged commit 4ad7ddf into pulp:master Apr 26, 2019
3 checks passed
3 checks passed
Travis CI - Pull Request Build Passed
Details
codecov/patch 90% of diff hit (target 67.79%)
Details
codecov/project 67.8% (+0.01%) compared to 31bda7b
Details
@dkliban dkliban deleted the dkliban:ssl-fields branch Apr 26, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.