tlsfuzzer.utils.lists module
Utility functions for lists.
- tlsfuzzer.utils.lists.natural_sort_keys(key, _nsre=re.compile('([0-9]+)'))[source]
Split the key into a sortable list for the
sorted()
builtin.Natural sort sorts words using dictionary order and numbers using numerical order, so
ab20
will be placed beforeab100
.Used with
sorted()
like this:a = dict() b = sorted(a, key=natural_sort_keys)
- Parameters:
key – key used for sorting
- Return type: