scanoss 1.22.0__py3-none-any.whl → 1.24.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- scanoss/__init__.py +1 -1
- scanoss/api/geoprovenance/v2/scanoss_geoprovenance_pb2.py +49 -0
- scanoss/api/geoprovenance/v2/scanoss_geoprovenance_pb2_grpc.py +142 -0
- scanoss/cli.py +206 -40
- scanoss/components.py +21 -11
- scanoss/constants.py +2 -0
- scanoss/cryptography.py +274 -0
- scanoss/data/build_date.txt +1 -1
- scanoss/scanners/scanner_hfh.py +2 -1
- scanoss/scanossgrpc.py +115 -47
- scanoss/utils/file.py +2 -2
- {scanoss-1.22.0.dist-info → scanoss-1.24.0.dist-info}/METADATA +1 -1
- {scanoss-1.22.0.dist-info → scanoss-1.24.0.dist-info}/RECORD +19 -18
- {scanoss-1.22.0.dist-info → scanoss-1.24.0.dist-info}/WHEEL +1 -1
- scanoss/api/provenance/v2/scanoss_provenance_pb2.py +0 -41
- scanoss/api/provenance/v2/scanoss_provenance_pb2_grpc.py +0 -108
- /scanoss/api/{provenance → geoprovenance}/__init__.py +0 -0
- /scanoss/api/{provenance → geoprovenance}/v2/__init__.py +0 -0
- {scanoss-1.22.0.dist-info → scanoss-1.24.0.dist-info}/entry_points.txt +0 -0
- {scanoss-1.22.0.dist-info → scanoss-1.24.0.dist-info}/licenses/LICENSE +0 -0
- {scanoss-1.22.0.dist-info → scanoss-1.24.0.dist-info}/top_level.txt +0 -0
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
# -*- coding: utf-8 -*-
|
|
2
|
-
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
3
|
-
# source: scanoss/api/provenance/v2/scanoss-provenance.proto
|
|
4
|
-
"""Generated protocol buffer code."""
|
|
5
|
-
from google.protobuf.internal import builder as _builder
|
|
6
|
-
from google.protobuf import descriptor as _descriptor
|
|
7
|
-
from google.protobuf import descriptor_pool as _descriptor_pool
|
|
8
|
-
from google.protobuf import symbol_database as _symbol_database
|
|
9
|
-
# @@protoc_insertion_point(imports)
|
|
10
|
-
|
|
11
|
-
_sym_db = _symbol_database.Default()
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
from scanoss.api.common.v2 import scanoss_common_pb2 as scanoss_dot_api_dot_common_dot_v2_dot_scanoss__common__pb2
|
|
15
|
-
from google.api import annotations_pb2 as google_dot_api_dot_annotations__pb2
|
|
16
|
-
from protoc_gen_swagger.options import annotations_pb2 as protoc__gen__swagger_dot_options_dot_annotations__pb2
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n2scanoss/api/provenance/v2/scanoss-provenance.proto\x12\x19scanoss.api.provenance.v2\x1a*scanoss/api/common/v2/scanoss-common.proto\x1a\x1cgoogle/api/annotations.proto\x1a,protoc-gen-swagger/options/annotations.proto\"\xd5\x03\n\x12ProvenanceResponse\x12\x42\n\x05purls\x18\x01 \x03(\x0b\x32\x33.scanoss.api.provenance.v2.ProvenanceResponse.Purls\x12\x35\n\x06status\x18\x02 \x01(\x0b\x32%.scanoss.api.common.v2.StatusResponse\x1a\x32\n\x10\x44\x65\x63laredLocation\x12\x0c\n\x04type\x18\x01 \x01(\t\x12\x10\n\x08location\x18\x02 \x01(\t\x1a\x31\n\x0f\x43uratedLocation\x12\x0f\n\x07\x63ountry\x18\x01 \x01(\t\x12\r\n\x05\x63ount\x18\x02 \x01(\x05\x1a\xdc\x01\n\x05Purls\x12\x0c\n\x04purl\x18\x01 \x01(\t\x12\x0f\n\x07version\x18\x02 \x01(\t\x12Z\n\x12\x64\x65\x63lared_locations\x18\x03 \x03(\x0b\x32>.scanoss.api.provenance.v2.ProvenanceResponse.DeclaredLocation\x12X\n\x11\x63urated_locations\x18\x04 \x03(\x0b\x32=.scanoss.api.provenance.v2.ProvenanceResponse.CuratedLocation2\x98\x02\n\nProvenance\x12s\n\x04\x45\x63ho\x12\".scanoss.api.common.v2.EchoRequest\x1a#.scanoss.api.common.v2.EchoResponse\"\"\x82\xd3\xe4\x93\x02\x1c\"\x17/api/v2/provenance/echo:\x01*\x12\x94\x01\n\x16GetComponentProvenance\x12\".scanoss.api.common.v2.PurlRequest\x1a-.scanoss.api.provenance.v2.ProvenanceResponse\"\'\x82\xd3\xe4\x93\x02!\"\x1c/api/v2/provenance/countries:\x01*B\x94\x02Z5github.com/scanoss/papi/api/provenancev2;provenancev2\x92\x41\xd9\x01\x12s\n\x1aSCANOSS Provenance Service\"P\n\x12scanoss-provenance\x12%https://github.com/scanoss/provenance\x1a\x13support@scanoss.com2\x03\x32.0*\x01\x01\x32\x10\x61pplication/json:\x10\x61pplication/jsonR;\n\x03\x34\x30\x34\x12\x34\n*Returned when the resource does not exist.\x12\x06\n\x04\x9a\x02\x01\x07\x62\x06proto3')
|
|
20
|
-
|
|
21
|
-
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, globals())
|
|
22
|
-
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'scanoss.api.provenance.v2.scanoss_provenance_pb2', globals())
|
|
23
|
-
if _descriptor._USE_C_DESCRIPTORS == False:
|
|
24
|
-
|
|
25
|
-
DESCRIPTOR._options = None
|
|
26
|
-
DESCRIPTOR._serialized_options = b'Z5github.com/scanoss/papi/api/provenancev2;provenancev2\222A\331\001\022s\n\032SCANOSS Provenance Service\"P\n\022scanoss-provenance\022%https://github.com/scanoss/provenance\032\023support@scanoss.com2\0032.0*\001\0012\020application/json:\020application/jsonR;\n\003404\0224\n*Returned when the resource does not exist.\022\006\n\004\232\002\001\007'
|
|
27
|
-
_PROVENANCE.methods_by_name['Echo']._options = None
|
|
28
|
-
_PROVENANCE.methods_by_name['Echo']._serialized_options = b'\202\323\344\223\002\034\"\027/api/v2/provenance/echo:\001*'
|
|
29
|
-
_PROVENANCE.methods_by_name['GetComponentProvenance']._options = None
|
|
30
|
-
_PROVENANCE.methods_by_name['GetComponentProvenance']._serialized_options = b'\202\323\344\223\002!\"\034/api/v2/provenance/countries:\001*'
|
|
31
|
-
_PROVENANCERESPONSE._serialized_start=202
|
|
32
|
-
_PROVENANCERESPONSE._serialized_end=671
|
|
33
|
-
_PROVENANCERESPONSE_DECLAREDLOCATION._serialized_start=347
|
|
34
|
-
_PROVENANCERESPONSE_DECLAREDLOCATION._serialized_end=397
|
|
35
|
-
_PROVENANCERESPONSE_CURATEDLOCATION._serialized_start=399
|
|
36
|
-
_PROVENANCERESPONSE_CURATEDLOCATION._serialized_end=448
|
|
37
|
-
_PROVENANCERESPONSE_PURLS._serialized_start=451
|
|
38
|
-
_PROVENANCERESPONSE_PURLS._serialized_end=671
|
|
39
|
-
_PROVENANCE._serialized_start=674
|
|
40
|
-
_PROVENANCE._serialized_end=954
|
|
41
|
-
# @@protoc_insertion_point(module_scope)
|
|
@@ -1,108 +0,0 @@
|
|
|
1
|
-
# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
|
|
2
|
-
"""Client and server classes corresponding to protobuf-defined services."""
|
|
3
|
-
import grpc
|
|
4
|
-
|
|
5
|
-
from scanoss.api.common.v2 import scanoss_common_pb2 as scanoss_dot_api_dot_common_dot_v2_dot_scanoss__common__pb2
|
|
6
|
-
from scanoss.api.provenance.v2 import scanoss_provenance_pb2 as scanoss_dot_api_dot_provenance_dot_v2_dot_scanoss__provenance__pb2
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
class ProvenanceStub(object):
|
|
10
|
-
"""*
|
|
11
|
-
Expose all of the SCANOSS Provenance RPCs here
|
|
12
|
-
"""
|
|
13
|
-
|
|
14
|
-
def __init__(self, channel):
|
|
15
|
-
"""Constructor.
|
|
16
|
-
|
|
17
|
-
Args:
|
|
18
|
-
channel: A grpc.Channel.
|
|
19
|
-
"""
|
|
20
|
-
self.Echo = channel.unary_unary(
|
|
21
|
-
'/scanoss.api.provenance.v2.Provenance/Echo',
|
|
22
|
-
request_serializer=scanoss_dot_api_dot_common_dot_v2_dot_scanoss__common__pb2.EchoRequest.SerializeToString,
|
|
23
|
-
response_deserializer=scanoss_dot_api_dot_common_dot_v2_dot_scanoss__common__pb2.EchoResponse.FromString,
|
|
24
|
-
)
|
|
25
|
-
self.GetComponentProvenance = channel.unary_unary(
|
|
26
|
-
'/scanoss.api.provenance.v2.Provenance/GetComponentProvenance',
|
|
27
|
-
request_serializer=scanoss_dot_api_dot_common_dot_v2_dot_scanoss__common__pb2.PurlRequest.SerializeToString,
|
|
28
|
-
response_deserializer=scanoss_dot_api_dot_provenance_dot_v2_dot_scanoss__provenance__pb2.ProvenanceResponse.FromString,
|
|
29
|
-
)
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
class ProvenanceServicer(object):
|
|
33
|
-
"""*
|
|
34
|
-
Expose all of the SCANOSS Provenance RPCs here
|
|
35
|
-
"""
|
|
36
|
-
|
|
37
|
-
def Echo(self, request, context):
|
|
38
|
-
"""Standard echo
|
|
39
|
-
"""
|
|
40
|
-
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
|
41
|
-
context.set_details('Method not implemented!')
|
|
42
|
-
raise NotImplementedError('Method not implemented!')
|
|
43
|
-
|
|
44
|
-
def GetComponentProvenance(self, request, context):
|
|
45
|
-
"""Get Provenance countries associated with a list of PURLs
|
|
46
|
-
"""
|
|
47
|
-
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
|
48
|
-
context.set_details('Method not implemented!')
|
|
49
|
-
raise NotImplementedError('Method not implemented!')
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
def add_ProvenanceServicer_to_server(servicer, server):
|
|
53
|
-
rpc_method_handlers = {
|
|
54
|
-
'Echo': grpc.unary_unary_rpc_method_handler(
|
|
55
|
-
servicer.Echo,
|
|
56
|
-
request_deserializer=scanoss_dot_api_dot_common_dot_v2_dot_scanoss__common__pb2.EchoRequest.FromString,
|
|
57
|
-
response_serializer=scanoss_dot_api_dot_common_dot_v2_dot_scanoss__common__pb2.EchoResponse.SerializeToString,
|
|
58
|
-
),
|
|
59
|
-
'GetComponentProvenance': grpc.unary_unary_rpc_method_handler(
|
|
60
|
-
servicer.GetComponentProvenance,
|
|
61
|
-
request_deserializer=scanoss_dot_api_dot_common_dot_v2_dot_scanoss__common__pb2.PurlRequest.FromString,
|
|
62
|
-
response_serializer=scanoss_dot_api_dot_provenance_dot_v2_dot_scanoss__provenance__pb2.ProvenanceResponse.SerializeToString,
|
|
63
|
-
),
|
|
64
|
-
}
|
|
65
|
-
generic_handler = grpc.method_handlers_generic_handler(
|
|
66
|
-
'scanoss.api.provenance.v2.Provenance', rpc_method_handlers)
|
|
67
|
-
server.add_generic_rpc_handlers((generic_handler,))
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
# This class is part of an EXPERIMENTAL API.
|
|
71
|
-
class Provenance(object):
|
|
72
|
-
"""*
|
|
73
|
-
Expose all of the SCANOSS Provenance RPCs here
|
|
74
|
-
"""
|
|
75
|
-
|
|
76
|
-
@staticmethod
|
|
77
|
-
def Echo(request,
|
|
78
|
-
target,
|
|
79
|
-
options=(),
|
|
80
|
-
channel_credentials=None,
|
|
81
|
-
call_credentials=None,
|
|
82
|
-
insecure=False,
|
|
83
|
-
compression=None,
|
|
84
|
-
wait_for_ready=None,
|
|
85
|
-
timeout=None,
|
|
86
|
-
metadata=None):
|
|
87
|
-
return grpc.experimental.unary_unary(request, target, '/scanoss.api.provenance.v2.Provenance/Echo',
|
|
88
|
-
scanoss_dot_api_dot_common_dot_v2_dot_scanoss__common__pb2.EchoRequest.SerializeToString,
|
|
89
|
-
scanoss_dot_api_dot_common_dot_v2_dot_scanoss__common__pb2.EchoResponse.FromString,
|
|
90
|
-
options, channel_credentials,
|
|
91
|
-
insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
|
|
92
|
-
|
|
93
|
-
@staticmethod
|
|
94
|
-
def GetComponentProvenance(request,
|
|
95
|
-
target,
|
|
96
|
-
options=(),
|
|
97
|
-
channel_credentials=None,
|
|
98
|
-
call_credentials=None,
|
|
99
|
-
insecure=False,
|
|
100
|
-
compression=None,
|
|
101
|
-
wait_for_ready=None,
|
|
102
|
-
timeout=None,
|
|
103
|
-
metadata=None):
|
|
104
|
-
return grpc.experimental.unary_unary(request, target, '/scanoss.api.provenance.v2.Provenance/GetComponentProvenance',
|
|
105
|
-
scanoss_dot_api_dot_common_dot_v2_dot_scanoss__common__pb2.PurlRequest.SerializeToString,
|
|
106
|
-
scanoss_dot_api_dot_provenance_dot_v2_dot_scanoss__provenance__pb2.ProvenanceResponse.FromString,
|
|
107
|
-
options, channel_credentials,
|
|
108
|
-
insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|