Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
S
Signing verification utilities
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Seal
Building blocks
Signing verification utilities
Commits
852ab6c4
Commit
852ab6c4
authored
4 years ago
by
Igor Markin
Browse files
Options
Downloads
Patches
Plain Diff
Add build
parent
02fac5e2
No related branches found
No related tags found
1 merge request
!76
Replace @vereign/png with @vereign/lib-png
Pipeline
#42700
passed
4 years ago
Stage: install
Stage: test
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
dist/services/SealService/extractSealFromMime.js
+3
-3
3 additions, 3 deletions
dist/services/SealService/extractSealFromMime.js
with
3 additions
and
3 deletions
dist/services/SealService/extractSealFromMime.js
+
3
−
3
View file @
852ab6c4
...
...
@@ -33,7 +33,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
Object
.
defineProperty
(
exports
,
"
__esModule
"
,
{
value
:
true
});
exports
.
findSealContainer
=
void
0
;
const
lib_mime_1
=
__importDefault
(
require
(
"
@vereign/lib-mime
"
));
const
png_1
=
__importStar
(
require
(
"
@vereign/png
"
));
const
lib_
png_1
=
__importStar
(
require
(
"
@vereign/
lib-
png
"
));
const
url_parse_1
=
__importDefault
(
require
(
"
url-parse
"
));
const
SealReadingError_1
=
__importDefault
(
require
(
"
./SealReadingError
"
));
const
__1
=
require
(
"
../..
"
);
...
...
@@ -99,8 +99,8 @@ const extractSealPublicKey = (sealContainer, mime) => {
if
(
!
sealImageAttachment
)
{
throw
new
SealReadingError_1
.
default
(
"
Seal not found
"
,
SealReadingError_1
.
default
.
SEAL_NOT_FOUND
,
SealReadingError_1
.
default
.
SEVERITY_WARNING
);
}
const
png
=
png_1
.
default
.
readPng
(
new
Uint8Array
(
__1
.
base64ToArrayBuffer
(
sealImageAttachment
.
base64
)));
const
metadata
=
png_1
.
getMetaData
(
png
);
const
png
=
lib_
png_1
.
default
.
readPng
(
new
Uint8Array
(
__1
.
base64ToArrayBuffer
(
sealImageAttachment
.
base64
)));
const
metadata
=
lib_
png_1
.
getMetaData
(
png
);
const
sealMarker
=
metadata
[
"
v-seal
"
];
if
(
!
sealMarker
)
{
throw
new
SealReadingError_1
.
default
(
'
Seal not found. Seal marker "v-seal" is missing in picture metadata
'
,
SealReadingError_1
.
default
.
SEAL_NOT_FOUND
,
SealReadingError_1
.
default
.
SEVERITY_WARNING
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment