1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-25 23:21:54 +03:00
samba-mirror/python/samba
David Mulder 0f3066abbb gpo: Properly decode utf-8/16 inf files from bytes
This code was python 2 specific (string handling
has changed dramatically in python 3), and didn't
correctly decode utf-16 in python3. We should
instead read the file as bytes, then attempt a
utf-8 decode (the default), and try utf-16 if
encountering a decode failure.
The existing code actually throws an exception on
the initial file read when the data is utf-16,
since it tries to decode the bytes to a utf-8
string.

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
2020-08-06 16:38:36 +00:00
..
emulate traffic_packets: fix SyntaxWarning: "is" with a literal 2020-04-27 12:19:58 +00:00
gp_parse python/samba/gp_parse: Fix test errors with python3.8 2020-03-19 20:46:42 +00:00
kcc samba_kcc: avoid ValueError when local connections are less than 2 2019-12-18 11:37:53 +00:00
netcmd python: wrap 'import dckeytab' in an explanatory function 2020-07-17 07:17:40 +00:00
provision python: do not always import urllib 2020-06-13 05:25:31 +00:00
samba3
subunit
tests gpo: Test proper decoding of utf-16 inf files 2020-08-06 16:38:36 +00:00
__init__.py python: wrap 'import dckeytab' in an explanatory function 2020-07-17 07:17:40 +00:00
auth_util.py python: fix slow's mail address 2020-06-05 10:32:30 +00:00
colour.py
common.py
compat.py python: samba.compat rejects Python 2 2020-07-17 08:39:37 +00:00
dbchecker.py dbcheck: Allow a dangling forward link outside our known NCs 2020-07-29 03:19:02 +00:00
descriptor.py
dnsserver.py
domain_update.py
drs_utils.py
forest_update.py
getopt.py python getopt: Add bytes option type 2019-07-02 02:23:08 +00:00
gp_ext_loader.py
gp_scripts_ext.py gpo: Scripts gpo add warning about generated scripts 2020-08-06 16:38:36 +00:00
gp_sec_ext.py
gp_sudoers_ext.py gpo: Apply Group Policy Sudo Rights 2020-08-06 16:38:36 +00:00
gpclass.py gpo: Properly decode utf-8/16 inf files from bytes 2020-08-06 16:38:36 +00:00
graph.py
hostconfig.py
idmap.py
join.py python/join: use the provided krbtgt link in cleanup_old_accounts 2020-07-17 07:17:40 +00:00
logger.py
mdb_util.py
ms_display_specifiers.py
ms_forest_updates_markdown.py python/ms_forest_updates_markdown: avoid implicit global variable 2020-07-17 07:17:39 +00:00
ms_schema_markdown.py
ms_schema.py
ndr.py
ntacls.py pysmbd: add "session_info" arg tp py_smbd_create_file() 2019-12-20 11:41:42 +00:00
remove_dc.py
samdb.py samba-tool group addmembers: add --member-base-dn option for group member search 2020-01-21 14:38:47 +00:00
schema.py schema.py: avoid inefficient string concatenations 2019-09-24 12:22:44 +00:00
sd_utils.py
sites.py
subnets.py
tdb_util.py
upgrade.py classicupgrade: fix a a bytes-like object is required, not 'str' error 2019-09-23 12:58:20 +00:00
upgradehelpers.py python/upgradehelpers: remove unused imports and variables 2020-07-17 07:17:40 +00:00
uptodateness.py
xattr.py