The Samba-Bugzilla – Attachment 4689 Details for
Bug 6723
Python bindings for samba produce a segfault with as_sddl
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
Test case for this bug
demosegfault2.py (text/x-python), 1.51 KB, created by
Matthieu Patou
on 2009-09-14 09:20:46 UTC
(
hide
)
Description:
Test case for this bug
Filename:
MIME Type:
Creator:
Matthieu Patou
Created:
2009-09-14 09:20:46 UTC
Size:
1.51 KB
patch
obsolete
>#!/usr/bin/python ># ># Copyright (C) Matthieu Patou <mat@matws.net> 2009 >import sys >import optparse >sys.path.insert(0, "bin/python") > >import samba >from samba.credentials import DONT_USE_KERBEROS >from samba.auth import system_session >from samba import Ldb, substitute_var, valid_netbios_name, check_all_substituted >from ldb import SCOPE_SUBTREE, SCOPE_ONELEVEL, SCOPE_BASE, LdbError, \ > timestring, CHANGETYPE_MODIFY, CHANGETYPE_NONE >import ldb >import samba.getopt as options >from samba.samdb import SamDB >from samba import param >from samba.provision import ProvisionPaths, ProvisionNames,provision_paths_from_lp,setup_add_ldif,find_setup_dir,Schema,get_linked_attributes,FILL_FULL,provision >from samba.dcerpc import misc, security >from samba.ndr import ndr_pack, ndr_unpack > >parser = optparse.OptionParser("provision [options]") >sambaopts = options.SambaOptions(parser) >parser.add_option_group(sambaopts) >parser.add_option_group(options.VersionOptions(parser)) >credopts = options.CredentialsOptions(parser) >parser.add_option_group(credopts) >opts = parser.parse_args()[0] >lp = sambaopts.get_loadparm() >smbconf = lp.configfile > >creds = credopts.get_credentials(lp) >creds.set_kerberos_state(DONT_USE_KERBEROS) >session = system_session() > >testSD="O:S-1-5-21-123456789-987654321-1234567890-500G:S-1-5-21-123456789-987654321-1234567890-513D:S:" >txtSID="S-1-5-21-123456789-987654321-1234567890" >domsid=security.dom_sid(txtSID) >descr = security.descriptor.from_sddl(testSD, domsid) >print descr.as_sddl(domsid) >#boom >print descr.as_sddl(txtSID) >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 6723
: 4689 |
4713