<feed xmlns='http://www.w3.org/2005/Atom'>
<title>samba.git/python/samba/gp_parse/gp_csv.py, branch talloc-2.3.1</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.</subtitle>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/'/>
<entry>
<title>py3: io.open takes a numeric buffering argument at index 2</title>
<updated>2019-03-12T00:42:20+00:00</updated>
<author>
<name>Garming Sam</name>
<email>garming@catalyst.net.nz</email>
</author>
<published>2019-02-21T02:11:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=2e231541b48fc97ca013079585ef556efda6cb95'/>
<id>2e231541b48fc97ca013079585ef556efda6cb95</id>
<content type='text'>
It's unsure why this doesn't fail generically, but it fails on my machine sometimes...

Signed-off-by: Garming Sam &lt;garming@catalyst.net.nz&gt;
Reviewed-by: Andrew Bartlett &lt;abartlet@samba.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It's unsure why this doesn't fail generically, but it fails on my machine sometimes...

Signed-off-by: Garming Sam &lt;garming@catalyst.net.nz&gt;
Reviewed-by: Andrew Bartlett &lt;abartlet@samba.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>python/samba/gp_parse: PY2/PY3 Decode only when necessary</title>
<updated>2018-11-05T19:05:24+00:00</updated>
<author>
<name>Noel Power</name>
<email>noel.power@suse.com</email>
</author>
<published>2018-09-05T16:01:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=fc047c2cf458e08e2689ff27677d8622f4507c82'/>
<id>fc047c2cf458e08e2689ff27677d8622f4507c82</id>
<content type='text'>
In python2 we decode str types in load_xml, in python3 these are
str class(s) which we cannot decode.

Signed-off-by: Noel Power &lt;noel.power@suse.com&gt;
Reviewed-by: Douglas Bagnall &lt;douglas.bagnall@catalyst.net.nz&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In python2 we decode str types in load_xml, in python3 these are
str class(s) which we cannot decode.

Signed-off-by: Noel Power &lt;noel.power@suse.com&gt;
Reviewed-by: Douglas Bagnall &lt;douglas.bagnall@catalyst.net.nz&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>python/samab/gp_parse: remove unused code</title>
<updated>2018-11-05T19:05:23+00:00</updated>
<author>
<name>Noel Power</name>
<email>noel.power@suse.com</email>
</author>
<published>2018-09-05T13:39:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=54e2bb707bc998e9017ab3818f8df45c95fad3ce'/>
<id>54e2bb707bc998e9017ab3818f8df45c95fad3ce</id>
<content type='text'>
Signed-off-by: Noel Power &lt;noel.power@suse.com&gt;
Reviewed-by: Douglas Bagnall &lt;douglas.bagnall@catalyst.net.nz&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Noel Power &lt;noel.power@suse.com&gt;
Reviewed-by: Douglas Bagnall &lt;douglas.bagnall@catalyst.net.nz&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>python/samba/gp_parse: Use csv.reader for parsing cvs files</title>
<updated>2018-11-05T19:05:23+00:00</updated>
<author>
<name>Noel Power</name>
<email>noel.power@suse.com</email>
</author>
<published>2018-09-05T13:18:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=df578e1554630f6781d40d4820c9026bb7b01d2d'/>
<id>df578e1554630f6781d40d4820c9026bb7b01d2d</id>
<content type='text'>
The previous version here was using UnicodeReader which was
wrapping the UTF8Recoder class and passing that to csv.reader.
It looks like the intention was to read a bytestream in a
certain encoding and then reencode it to a different encoding.
And then UnicodeReader creates unicode from the newly encoded stream.
This is unnecssary, we know the encoding of the bytesstream and
codec.getreader will happily consume the bytstream and give back
unicode. The unicode can be fed directly into csv.writer.

Signed-off-by: Noel Power &lt;noel.power@suse.com&gt;
Reviewed-by: Douglas Bagnall &lt;douglas.bagnall@catalyst.net.nz&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The previous version here was using UnicodeReader which was
wrapping the UTF8Recoder class and passing that to csv.reader.
It looks like the intention was to read a bytestream in a
certain encoding and then reencode it to a different encoding.
And then UnicodeReader creates unicode from the newly encoded stream.
This is unnecssary, we know the encoding of the bytesstream and
codec.getreader will happily consume the bytstream and give back
unicode. The unicode can be fed directly into csv.writer.

Signed-off-by: Noel Power &lt;noel.power@suse.com&gt;
Reviewed-by: Douglas Bagnall &lt;douglas.bagnall@catalyst.net.nz&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>python/samba/gp_parse: PY3 open file non-binary mode for write_binary</title>
<updated>2018-11-05T19:05:23+00:00</updated>
<author>
<name>Noel Power</name>
<email>noel.power@suse.com</email>
</author>
<published>2018-09-05T11:52:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=d40ef736d5ee34ad5b575dc32f89d0f4cc1885b8'/>
<id>d40ef736d5ee34ad5b575dc32f89d0f4cc1885b8</id>
<content type='text'>
Although this is unintuitive it's because we are writing unicode
not bytes (both in PY2 &amp; PY3). using the 'b' mode causes an error in
PY3.

In PY3 we can define the encoding, but not in PY2.

Signed-off-by: Noel Power &lt;noel.power@suse.com&gt;
Reviewed-by: Douglas Bagnall &lt;douglas.bagnall@catalyst.net.nz&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Although this is unintuitive it's because we are writing unicode
not bytes (both in PY2 &amp; PY3). using the 'b' mode causes an error in
PY3.

In PY3 we can define the encoding, but not in PY2.

Signed-off-by: Noel Power &lt;noel.power@suse.com&gt;
Reviewed-by: Douglas Bagnall &lt;douglas.bagnall@catalyst.net.nz&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>python/samba/gp_parse: PY3 file -&gt; open</title>
<updated>2018-11-05T19:05:23+00:00</updated>
<author>
<name>Noel Power</name>
<email>noel.power@suse.com</email>
</author>
<published>2018-09-05T11:46:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=388bddf4a6471f17f32af209bec36713f0b75d20'/>
<id>388bddf4a6471f17f32af209bec36713f0b75d20</id>
<content type='text'>
'file' no longer exists in PY3 replace with 'open'

Signed-off-by: Noel Power &lt;noel.power@suse.com&gt;
Reviewed-by: Douglas Bagnall &lt;douglas.bagnall@catalyst.net.nz&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
'file' no longer exists in PY3 replace with 'open'

Signed-off-by: Noel Power &lt;noel.power@suse.com&gt;
Reviewed-by: Douglas Bagnall &lt;douglas.bagnall@catalyst.net.nz&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>gp_csv: Add CSV generalization metadata</title>
<updated>2018-08-16T21:42:21+00:00</updated>
<author>
<name>Garming Sam</name>
<email>garming@catalyst.net.nz</email>
</author>
<published>2018-05-29T21:43:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=ee010392d5e8072acc1623c5eab453599af88656'/>
<id>ee010392d5e8072acc1623c5eab453599af88656</id>
<content type='text'>
There are user identifiers and ACLs which may be stored in the audit CSV.

Signed-off-by: Garming Sam &lt;garming@catalyst.net.nz&gt;
Reviewed-by: Andrew Bartlett &lt;abartlet@samba.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
There are user identifiers and ACLs which may be stored in the audit CSV.

Signed-off-by: Garming Sam &lt;garming@catalyst.net.nz&gt;
Reviewed-by: Andrew Bartlett &lt;abartlet@samba.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>gp_csv: Parse the audit.csv file which records audit settings</title>
<updated>2018-08-16T21:42:21+00:00</updated>
<author>
<name>Garming Sam</name>
<email>garming@catalyst.net.nz</email>
</author>
<published>2018-05-10T05:15:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=4a69308b7a5fa3f14681fd951999500129ee5bea'/>
<id>4a69308b7a5fa3f14681fd951999500129ee5bea</id>
<content type='text'>
Based on the setting, the csv will omit certain fields. Using this we
can later infer as to how to generalize the ACLs and SIDs.

Signed-off-by: Garming Sam &lt;garming@catalyst.net.nz&gt;
Reviewed-by: Andrew Bartlett &lt;abartlet@samba.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Based on the setting, the csv will omit certain fields. Using this we
can later infer as to how to generalize the ACLs and SIDs.

Signed-off-by: Garming Sam &lt;garming@catalyst.net.nz&gt;
Reviewed-by: Andrew Bartlett &lt;abartlet@samba.org&gt;
</pre>
</div>
</content>
</entry>
</feed>
