Skip to content

Commit d6b9a95

Browse files
committed
Update link references of ownership from nexB to aboutcode-org
Signed-off-by: Chin Yeung Li <tli@nexb.com>
1 parent ff21d52 commit d6b9a95

111 files changed

Lines changed: 515 additions & 393 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

README.rst

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
ScanCode plugins
1+
ScanCode plugins
22
================
33

4-
https://github.com/nexB/scancode-plugins
4+
https://github.com/aboutcode-org/scancode-plugins
55

66
These are various scancode plugins, some are builtins and some are extras.
77
Several of them contain pre-built binaries.
@@ -17,14 +17,14 @@ native binaries.
1717

1818
See also:
1919

20-
- https://github.com/nexB/scancode-toolkit
20+
- https://github.com/aboutcode-org/scancode-toolkit
2121
- https://github.com/nexB/scancode-thirdparty-src (source for some plugins
2222
being transitioned)
2323

2424

2525
To re-provision pre-built binaries, follow these instructions (only on Linux):
2626

27-
- install the system package for clamav, zstd and p7zip
27+
- install the system package for clamav, zstd and p7zip
2828
- install the patchelf from sources (provided here in src/). This is done for
2929
you automatically below with a configure run. Older versions may be buggy.
3030

@@ -33,7 +33,7 @@ To re-provision pre-built binaries, follow these instructions (only on Linux):
3333
./configure
3434
etc/scripts/fetch-plugins.sh
3535
clamscan -v *
36-
36+
3737
In all cases, run clamscan or an up to date antivirus scanner before pushing
3838
a new release.
3939

binary-analysis/scancode-compiledcode/NOTICE

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ ScanCode software is licensed under the Apache License version 2.0.
1010

1111
See https://www.apache.org/licenses/LICENSE-2.0 for the Apache-2.0 license text.
1212

13-
See https://github.com/nexB/scancode-plugins for support or download.
13+
See https://github.com/aboutcode-org/scancode-plugins for support or download.
1414
See https://aboutcode.org for more information about nexB OSS projects
1515

1616

@@ -26,11 +26,11 @@ The corresponding source code for pre-compiled third-party software is available
2626
for immediate download from the same release page where you obtained ScanCode,
2727
including:
2828

29-
- https://github.com/nexB/scancode-toolkit/
29+
- https://github.com/aboutcode-org/scancode-toolkit/
3030
- https://pypi.org/project/scancode-toolkit/
3131
- https://thirdparty.aboutcode.org/pypi/
3232
- https://github.com/nexB/thirdparty-packages/pypi/
33-
- https://github.com/nexB/scancode-plugins/
33+
- https://github.com/aboutcode-org/scancode-plugins/
3434
- https://github.com/nexB/scancode-thirdparty-src/
3535

3636
You may also contact us to request the source code by email at info@nexb.com or
@@ -40,4 +40,4 @@ by postal mail at:
4040
4966 El Camino Real #119, Los Altos, CA 94022, USA
4141

4242
Please indicate in your communication the ScanCode tool and version for which
43-
you are requesting source code.
43+
you are requesting source code.

binary-analysis/scancode-compiledcode/setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
long_description=desc,
2020
author='nexB',
2121
author_email='info@aboutcode.org',
22-
url='https://github.com/nexB/scancode-plugins/binary-analysis/scancode-compiledcode',
22+
url='https://github.com/aboutcode-org/scancode-plugins/binary-analysis/scancode-compiledcode',
2323
packages=find_packages('src'),
2424
package_dir={'': 'src'},
2525
py_modules=[splitext(basename(path))[0] for path in glob('src/*.py')],

binary-analysis/scancode-compiledcode/src/compiledcode/cppincludes.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# ScanCode is a trademark of nexB Inc.
55
# SPDX-License-Identifier: Apache-2.0
66
# See http://www.apache.org/licenses/LICENSE-2.0 for the license text.
7-
# See https://github.com/nexB/scancode-toolkit for support or download.
7+
# See https://github.com/aboutcode-org/scancode-toolkit for support or download.
88
# See https://aboutcode.org for more information about nexB OSS projects.
99
#
1010

@@ -31,10 +31,10 @@ class CPPIncludesScanner(ScanPlugin):
3131

3232
options = [
3333
PluggableCommandLineOption(('--cpp-includes',),
34-
is_flag=True, default=False,
35-
help='Collect the #includes statements in a C/C++ file.',
36-
help_group=SCAN_GROUP,
37-
sort_order=100),
34+
is_flag=True, default=False,
35+
help='Collect the #includes statements in a C/C++ file.',
36+
help_group=SCAN_GROUP,
37+
sort_order=100),
3838
]
3939

4040
def is_enabled(self, cpp_includes, **kwargs):

binary-analysis/scancode-compiledcode/src/compiledcode/dwarf/__init__.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# ScanCode is a trademark of nexB Inc.
55
# SPDX-License-Identifier: Apache-2.0
66
# See http://www.apache.org/licenses/LICENSE-2.0 for the license text.
7-
# See https://github.com/nexB/scancode-plugins for support or download.
7+
# See https://github.com/aboutcode-org/scancode-plugins for support or download.
88
# See https://aboutcode.org for more information about nexB OSS projects.
99
#
1010

@@ -38,12 +38,12 @@ class DwarfScanner(ScanPlugin):
3838

3939
options = [
4040
PluggableCommandLineOption(('--dwarf',),
41-
is_flag=True, default=False,
42-
help='Collect source code path from compilation units found in '
43-
'ELF DWARFs.',
44-
help_group=SCAN_GROUP,
45-
sort_order=100
46-
),
41+
is_flag=True, default=False,
42+
help='Collect source code path from compilation units found in '
43+
'ELF DWARFs.',
44+
help_group=SCAN_GROUP,
45+
sort_order=100
46+
),
4747
]
4848

4949
def is_enabled(self, dwarf, **kwargs):
@@ -58,7 +58,7 @@ def get_dwarfs(location, **kwargs):
5858
Return a mapping with original_source_files and included_source_files or None.
5959
"""
6060
return dict(
61-
# dwarf_source_path=list(dwarf_source_path(location))
61+
# dwarf_source_path=list(dwarf_source_path(location))
6262
dwarf_source_path=list(dwarf_source_path_ng(location))
6363
)
6464

binary-analysis/scancode-compiledcode/src/compiledcode/dwarf/dwarf.py

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# ScanCode is a trademark of nexB Inc.
55
# SPDX-License-Identifier: Apache-2.0
66
# See http://www.apache.org/licenses/LICENSE-2.0 for the license text.
7-
# See https://github.com/nexB/scancode-plugins for support or download.
7+
# See https://github.com/aboutcode-org/scancode-plugins for support or download.
88
# See https://aboutcode.org for more information about nexB OSS projects.
99
#
1010

@@ -101,7 +101,8 @@ def _parseinfo(self):
101101
error = open(err).read()
102102
if error:
103103
if 'bin/dwarfdump2' in error:
104-
self.parse_errors.append(error[error.index('bin/dwarfdump2'):])
104+
self.parse_errors.append(
105+
error[error.index('bin/dwarfdump2'):])
105106
else:
106107
self.parse_errors.append(error)
107108

@@ -117,10 +118,10 @@ def cleanup(self):
117118
original, std_includes = cleanup(self._files)
118119

119120
self.included_source_files.extend(x for x in std_includes
120-
if x not in self.included_source_files)
121+
if x not in self.included_source_files)
121122

122123
self.original_source_files.extend(x for x in original
123-
if x not in self.original_source_files)
124+
if x not in self.original_source_files)
124125

125126
def asdict(self):
126127
return dict([
@@ -240,7 +241,8 @@ def parse(self, dwarf, location):
240241
if posixpath.isabs(self.cu_filename):
241242
dwarf._files.append(self.cu_filename)
242243
else:
243-
dwarf._files.append(posixpath.join(self.cu_comp_dir, self.cu_filename))
244+
dwarf._files.append(posixpath.join(
245+
self.cu_comp_dir, self.cu_filename))
244246

245247
dwarf._files.extend(self.files)
246248

@@ -255,4 +257,5 @@ def parse_local_symbols(self, location):
255257
if posixpath.isabs(filename):
256258
self.files.append(filename)
257259
else:
258-
self.files.append(posixpath.join(self.cu_comp_dir, filename))
260+
self.files.append(posixpath.join(
261+
self.cu_comp_dir, filename))

binary-analysis/scancode-compiledcode/src/compiledcode/dwarf/dwarf2.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# ScanCode is a trademark of nexB Inc.
55
# SPDX-License-Identifier: Apache-2.0
66
# See http://www.apache.org/licenses/LICENSE-2.0 for the license text.
7-
# See https://github.com/nexB/scancode-plugins for support or download.
7+
# See https://github.com/aboutcode-org/scancode-plugins for support or download.
88
# See https://aboutcode.org for more information about nexB OSS projects.
99
#
1010

binary-analysis/scancode-compiledcode/src/compiledcode/dwarf/dwarfng.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# ScanCode is a trademark of nexB Inc.
55
# SPDX-License-Identifier: Apache-2.0
66
# See http://www.apache.org/licenses/LICENSE-2.0 for the license text.
7-
# See https://github.com/nexB/scancode-plugins for support or download.
7+
# See https://github.com/aboutcode-org/scancode-plugins for support or download.
88
# See https://aboutcode.org for more information about nexB OSS projects.
99
#
1010

@@ -89,7 +89,8 @@ def get_dwarf_cu_and_die_paths(location):
8989
file_entry = die_lineprogram.header.file_entry[decl_file_attrib.value - 1]
9090
fname = bytes2str(file_entry.name)
9191
try:
92-
file_dir = bytes2str(die_lineprogram['include_directory'][file_entry.dir_index - 1])
92+
file_dir = bytes2str(
93+
die_lineprogram['include_directory'][file_entry.dir_index - 1])
9394
except:
9495
continue
9596

@@ -99,7 +100,8 @@ def get_dwarf_cu_and_die_paths(location):
99100
seen.add(path)
100101

101102
comp_dir_attr = die.attributes.get('DW_AT_comp_dir', None)
102-
comp_dir = bytes2str(comp_dir_attr.value) if comp_dir_attr else ''
103+
comp_dir = bytes2str(
104+
comp_dir_attr.value) if comp_dir_attr else ''
103105
fname_attr = die.attributes.get('DW_AT_name', None)
104106
fname = bytes2str(fname_attr.value) if fname_attr else ''
105107
if comp_dir:

binary-analysis/scancode-compiledcode/src/compiledcode/elf/__init__.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# ScanCode is a trademark of nexB Inc.
55
# SPDX-License-Identifier: Apache-2.0
66
# See http://www.apache.org/licenses/LICENSE-2.0 for the license text.
7-
# See https://github.com/nexB/scancode-plugins for support or download.
7+
# See https://github.com/aboutcode-org/scancode-plugins for support or download.
88
# See https://aboutcode.org for more information about nexB OSS projects.
99
#
1010

@@ -35,10 +35,10 @@ class ELFScanner(ScanPlugin):
3535

3636
options = [
3737
PluggableCommandLineOption(('--elf',),
38-
is_flag=True, default=False,
39-
help='Collect dependent libraries names needed by an Elf file.',
40-
help_group=SCAN_GROUP,
41-
sort_order=100),
38+
is_flag=True, default=False,
39+
help='Collect dependent libraries names needed by an Elf file.',
40+
help_group=SCAN_GROUP,
41+
sort_order=100),
4242
]
4343

4444
def is_enabled(self, elf, **kwargs):
@@ -52,7 +52,7 @@ def get_elf_needed_library_ng(location, **kwargs):
5252
"""
5353
Return a list of needed_libraries
5454
"""
55-
results = [enl for enl in elfng.get_elf_needed_library(location)]
55+
results = [enl for enl in elfng.get_elf_needed_library(location)]
5656
return dict(elf_needed_library=results)
5757

5858

@@ -66,6 +66,6 @@ def get_elf_needed_library(location, **kwargs):
6666
return
6767
elfie = Elf(location)
6868
results = []
69-
for needed_library in elfie.needed_libraries:
69+
for needed_library in elfie.needed_libraries:
7070
results.append(needed_library)
7171
return dict(elf_needed_library=results)

binary-analysis/scancode-compiledcode/src/compiledcode/elf/elf.py

Lines changed: 26 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# ScanCode is a trademark of nexB Inc.
55
# SPDX-License-Identifier: Apache-2.0
66
# See http://www.apache.org/licenses/LICENSE-2.0 for the license text.
7-
# See https://github.com/nexB/scancode-plugins for support or download.
7+
# See https://github.com/aboutcode-org/scancode-plugins for support or download.
88
# See https://aboutcode.org for more information about nexB OSS projects.
99
#
1010

@@ -31,7 +31,7 @@
3131

3232
def next_line(file_desc):
3333
try:
34-
return file_desc.next()
34+
return file_desc.next()
3535
except:
3636
return None
3737

@@ -77,11 +77,11 @@ def __init__(self, location):
7777

7878
def symbols(self):
7979
return sorted(flatten([list(self.symbols_section.local_functions),
80-
list(self.symbols_section.global_functions)]))
80+
list(self.symbols_section.global_functions)]))
8181

8282
def setup_handlers(self):
8383
self.readelf_options = set([s.readelf_option
84-
for s in self.readelf_sections])
84+
for s in self.readelf_sections])
8585
for s in self.readelf_sections:
8686
self.handlers[s.start_re] = s
8787

@@ -226,7 +226,7 @@ def demangle_chunk(symbols):
226226
lib_loc = get_location(SCANCODE_CPLUSPLUSFILT_LIB)
227227
rc, out, err = command.execute(
228228
cmd_loc, args,
229-
lib_dir=lib_loc,
229+
lib_dir=lib_loc,
230230
to_files=True,
231231
)
232232
if rc != 0:
@@ -255,7 +255,7 @@ def SYMBOLS_START_RE():
255255

256256

257257
def SYMBOLS_INTERESTING_RE():
258-
# 51: 0804bf30 0 FUNC LOCAL DEFAULT 14 __do_global_ctors_aux
258+
# 51: 0804bf30 0 FUNC LOCAL DEFAULT 14 __do_global_ctors_aux
259259
return re.compile(r"^\d*:\s+[A-Fa-f0-9]+\s+\d+\s+(FILE|FUNC|OBJECT)\s+(LOCAL|GLOBAL)\s+DEFAULT\s+\w+\s+(.*)$")
260260

261261

@@ -273,14 +273,14 @@ def SYMBOLS_INTERESTING_RE():
273273
'call_gmon_start']
274274

275275
standardobj = ['__CTOR_LIST__',
276-
'__DTOR_LIST__',
277-
'__JCR_LIST__',
278-
'__CTOR_END__',
279-
'__DTOR_END__',
280-
'__FRAME_END__',
281-
'__JCR_END__',
282-
'_fp_hw',
283-
'_IO_stdin_used']
276+
'__DTOR_LIST__',
277+
'__JCR_LIST__',
278+
'__CTOR_END__',
279+
'__DTOR_END__',
280+
'__FRAME_END__',
281+
'__JCR_END__',
282+
'_fp_hw',
283+
'_IO_stdin_used']
284284

285285

286286
class ElfSymbolsTableSection(object):
@@ -368,17 +368,21 @@ def __init__(self):
368368
self.local_objects = set()
369369
self.global_objects = set()
370370
self.global_functions = set()
371-
self.locals = {"FUNC": self.local_functions, "OBJECT": self.local_objects}
372-
self.globals = {"FUNC": self.global_functions, "OBJECT": self.global_objects}
371+
self.locals = {"FUNC": self.local_functions,
372+
"OBJECT": self.local_objects}
373+
self.globals = {"FUNC": self.global_functions,
374+
"OBJECT": self.global_objects}
373375
self.locglobs = {"LOCAL": self.locals, "GLOBAL": self.globals}
374376

375377
self.external_libs_functions = set()
376378
self.external_libs_objects = set()
377-
self.externals = {"FUNC": self.external_libs_functions, "OBJECT": self.external_libs_objects}
379+
self.externals = {"FUNC": self.external_libs_functions,
380+
"OBJECT": self.external_libs_objects}
378381

379382
self.standard_functions = set()
380383
self.standard_objects = set()
381-
self.standards = {"FUNC": self.standard_functions, "OBJECT": self.standard_objects}
384+
self.standards = {"FUNC": self.standard_functions,
385+
"OBJECT": self.standard_objects}
382386

383387
self.shared_libs_references = set()
384388

@@ -398,14 +402,14 @@ def parse(self, elf, file_like):
398402
name, sharedlib = name.split("@@")
399403
self.shared_libs_references.add(name)
400404

401-
if _type == 'FILE' and not name.startswith("<") :
405+
if _type == 'FILE' and not name.startswith("<"):
402406
if name in standardfiles:
403407
self.standard_files.add(name)
404408
else:
405409
self.files.add(name)
406410

407411
if ((_type == 'FUNC' or _type == 'OBJECT')
408-
and not name.startswith("$")):
412+
and not name.startswith("$")):
409413
if sharedlib:
410414
self.externals[_type].add((name, sharedlib))
411415
elif name in standardfunc or name in standardobj:
@@ -493,7 +497,8 @@ class ElfSectionHeadersSection(object):
493497
# starts with start_line
494498

495499
# we need some sections to be able to et anything
496-
needed_sections = ['.debug_info', '.debug_line', '.symtab', '.dynsym', '.dynstr']
500+
needed_sections = ['.debug_info', '.debug_line',
501+
'.symtab', '.dynsym', '.dynstr']
497502
"""
498503
$ readelf --wide --section-headers tests/dependencies-testfiles/elf/ssdeep.i686 | more
499504
There are 39 section headers, starting at offset 0xf5ec:

0 commit comments

Comments
 (0)