Skip to content

Commit

Permalink
docs: Rename Samba3-Developers-Guide to Samba-Developers-Guide
Browse files Browse the repository at this point in the history
This guide is not obsolete but needs an update.

Signed-off-by: Karolin Seeger <[email protected]>
Reviewed-by: Andreas Schneider <[email protected]>

Autobuild-User(master): Andreas Schneider <[email protected]>
Autobuild-Date(master): Wed May 10 19:57:36 CEST 2017 on sn-devel-144
  • Loading branch information
kseeger authored and cryptomilk committed May 10, 2017
1 parent 8e52229 commit cc7ae10
Show file tree
Hide file tree
Showing 19 changed files with 282 additions and 283 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ document will attempt to document a few of the more important coding
practices used at this time on the Samba project. The coding practices are
expected to change slightly over time, and even to grow as more is learned
about obscure portability considerations. Two existing documents
<filename>samba/source/internals.doc</filename> and
<filename>samba/source/internals.doc</filename> and
<filename>samba/source/architecture.doc</filename> provide
additional information.
</para>
Expand Down Expand Up @@ -84,7 +84,7 @@ Here are some other suggestions:

<listitem><para>
use d_printf instead of printf for display text
reason: enable auto-substitution of translated language text
reason: enable auto-substitution of translated language text
</para></listitem>

<listitem><para>
Expand Down Expand Up @@ -115,7 +115,7 @@ Here are some other suggestions:
<listitem><para>
when passing a va_list as an arg, or assigning one to another
please use the VA_COPY() macro
reason: on some platforms, va_list is a struct that must be
reason: on some platforms, va_list is a struct that must be
initialized in each function...can SEGV if you don't.
</para></listitem>

Expand All @@ -125,13 +125,13 @@ Here are some other suggestions:
</para></listitem>

<listitem><para>
don't explicitly include new header files in C files - new h files
don't explicitly include new header files in C files - new h files
should be included by adding them once to includes.h
reason: consistency
</para></listitem>

<listitem><para>
don't explicitly extern functions (they are autogenerated by
don't explicitly extern functions (they are autogenerated by
"make proto" into proto.h)
reason: consistency
</para></listitem>
Expand Down Expand Up @@ -219,13 +219,13 @@ Here are some other suggestions:
for fragile, hand to maintain code. Instead, design an interface
and use tables containing function pointers to implement specific
functionality. This is particularly important for command
interpreters.
interpreters.
</para></listitem>

<listitem><para>
Think carefully about what it will be like for someone else to add
to and maintain your code. If it would be hard for someone else to
maintain then do it another way.
maintain then do it another way.
</para></listitem>

</orderedlist>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,14 @@ that they nearly all come with a system trace utility that allows you
to monitor all system calls that a program is making. This is
extremely using for debugging and also helps when trying to work out
why something is slower than you expect. You can use system tracing
without any special compilation options.
without any special compilation options.
</para>

<para>
The system trace utility is called different things on different
systems. On Linux systems its called strace. Under SunOS 4 its called
trace. Under SVR4 style systems (including solaris) its called
truss. Under many BSD systems its called ktrace.
truss. Under many BSD systems its called ktrace.
</para>

<para>
Expand All @@ -52,7 +52,7 @@ Next, try using strace on some simple commands. For example, <command>strace
ls</command> or <command>strace echo hello</command>.
</para>

<para>
<para>
You'll notice that it produces a LOT of output. It is showing you the
arguments to every system call that the program makes and the
result. Very little happens in a program without a system call so you
Expand Down Expand Up @@ -98,7 +98,7 @@ forks. This is great for finding printing problems caused by the
<para>
Once you are attached you then can do whatever it is on the client
that is causing problems and you will capture all the system calls
that smbd makes.
that smbd makes.
</para>

<para>
Expand All @@ -123,8 +123,8 @@ causes printing to fail with Samba:
</programlisting></para>

<para>
The process is trying to first open <filename>/dev/null</filename> read-write
then read-only. Both fail. This means <filename>/dev/null</filename> has
The process is trying to first open <filename>/dev/null</filename> read-write
then read-only. Both fail. This means <filename>/dev/null</filename> has
incorrect permissions.
</para>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ This document gives a general overview of how Samba works
internally. The Samba Team has tried to come up with a model which is
the best possible compromise between elegance, portability, security
and the constraints imposed by the very messy SMB and CIFS
protocol.
protocol.
</para>

<para>
Expand All @@ -45,7 +45,7 @@ It also tries to answer some of the frequently asked questions such as:
<para>
People sometimes tout threads as a uniformly good thing. They are very
nice in their place but are quite inappropriate for smbd. nmbd is
another matter, and multi-threading it would be very nice.
another matter, and multi-threading it would be very nice.
</para>

<para>
Expand Down Expand Up @@ -90,7 +90,7 @@ A few problems that would arise from a threaded smbd are:
many of the system calls we make are blocking. Non-blocking
equivalents of many calls are either not available or are awkward (and
slow) to use. So while we block in one thread all clients are
waiting. Imagine if one share is a slow NFS filesystem and the others
waiting. Imagine if one share is a slow NFS filesystem and the others
are fast, we will end up slowing all clients to the speed of NFS.
</para></listitem>

Expand Down Expand Up @@ -179,7 +179,7 @@ wire. It's a nice format that is very amenable to processing but still
keeps the idea of a distinct packet. See "struct packet_struct" in
nameserv.h. It has all the detail but none of the on-the-wire
mess. This makes it ideal for using in disk or memory-based databases
for browsing and WINS support.
for browsing and WINS support.
</para>

</sect1>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ instructive than this document.
</para>

<para>
Also needed, to fully implement NT Domain Login Services, is the
Also needed, to fully implement NT Domain Login Services, is the
document describing the cryptographic part of the NT authentication.
This document is available from comp.protocols.smb; from the ntsecurity.net
digest and from the samba digest, amongst other sources.
Expand Down Expand Up @@ -79,7 +79,7 @@ achieved by setting the following REG_SZ registry key to 0x1ffffff:
<para><filename>HKLM\SYSTEM\CurrentControlSet\Services\Netlogon\Parameters</filename></para>

<para><emphasis>Incorrect direct editing of the registry can cause your
machine to fail. Then again, so can incorrect implementation of this
machine to fail. Then again, so can incorrect implementation of this
protocol. See "Liability:" above.</emphasis></para>

<para>
Expand All @@ -103,11 +103,11 @@ include, but are not limited to:
<listitem><para>The exact meaning/definition of various magic constants or enumerations.</para></listitem>

<listitem><para>The reply error code and use of that error code when a
workstation becomes a member of a domain (to be described later).
Failure to return this error code will make the workstation report
workstation becomes a member of a domain (to be described later).
Failure to return this error code will make the workstation report
that it is already a member of the domain.</para></listitem>

<listitem><para>the cryptographic side of the NetrServerPasswordSet command,
<listitem><para>the cryptographic side of the NetrServerPasswordSet command,
which would allow the workstation to change its password. This password is
used to generate the long-term session key. [It is possible to reject this
command, and keep the default workstation password].</para></listitem>
Expand All @@ -129,7 +129,7 @@ command, and keep the default workstation password].</para></listitem>
<sect2>
<title>Credits</title>

<simplelist>
<simplelist>
<member>Paul Ashton: loads of work with Net Monitor; understanding the NT authentication system; reference implementation of the NT domain support on which this document is originally based.</member>
<member>Duncan Stansfield: low-level analysis of MSRPC Pipes.</member>
<member>Linus Nordberg: producing c-code from Paul's crypto spec.</member>
Expand Down Expand Up @@ -1226,7 +1226,7 @@ appears a third time after the last sub-structure.
<title>MSRPC Pipes</title>

<para>
The MSRPC is conducted over an SMB Transact Pipe with a name of
The MSRPC is conducted over an SMB Transact Pipe with a name of
<filename>\PIPE\</filename>. You must first obtain a 16 bit file handle, by
sending a SMBopenX with the pipe name <filename>\PIPE\srvsvc</filename> for
example. You can then perform an SMB Trans,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,17 @@

<title>Contributing code</title>

<para>Here are a few tips and notes that might be useful if you are
interested in modifying samba source code and getting it into
<para>Here are a few tips and notes that might be useful if you are
interested in modifying samba source code and getting it into
samba's main branch.</para>

<variablelist>
<varlistentry>
<term>Retrieving the source</term>

<listitem>
<para>In order to contribute code to samba, make sure you have the
latest source. Retrieving the samba source code from CVS is
<para>In order to contribute code to samba, make sure you have the
latest source. Retrieving the samba source code from CVS is
documented in the appendix of the Samba HOWTO Collection.
</para>
</listitem>
Expand All @@ -27,15 +27,15 @@
<varlistentry>
<term>Discuss large modifications with team members</term>
<listitem>
<para>Please discuss large modifications you are going to make
with members of the samba team. Some parts of the samba code
have one or more 'owners' - samba developers who wrote most
of the code and maintain it.
<para>Please discuss large modifications you are going to make
with members of the samba team. Some parts of the samba code
have one or more 'owners' - samba developers who wrote most
of the code and maintain it.
</para>

<para>This way you can avoid spending your time and effort on
something that is not going to make it into the main samba branch
because someone else was working on the same thing or because your
<para>This way you can avoid spending your time and effort on
something that is not going to make it into the main samba branch
because someone else was working on the same thing or because your
implementation is not the correct one.
</para>
</listitem>
Expand All @@ -44,13 +44,13 @@
<varlistentry>
<term>Patch format</term>
<listitem>
<para>Patches to the samba tree should be in unified diff format,
e.g. files generated by <userinput>diff -u</userinput>.
<para>Patches to the samba tree should be in unified diff format,
e.g. files generated by <userinput>diff -u</userinput>.
</para>

<para>If you are modifying a copy of samba you retrieved from CVS,
you can easily generate a diff file of these changes by running
<userinput>cvs diff -u</userinput>.</para>
<para>If you are modifying a copy of samba you retrieved from CVS,
you can easily generate a diff file of these changes by running
<userinput>cvs diff -u</userinput>.</para>
</listitem>
</varlistentry>

Expand All @@ -59,17 +59,17 @@
<listitem><para>
<itemizedlist>
<listitem><para>Don't simply copy code from other places and modify it until it
works. Code needs to be clean and logical. Duplicate
works. Code needs to be clean and logical. Duplicate
code is to be avoided.</para></listitem>
<listitem><para>Test your patch. It might take a while before one of us looks
at your patch so it will take longer before your patch when your patch
<listitem><para>Test your patch. It might take a while before one of us looks
at your patch so it will take longer before your patch when your patch
needs to go thru the review cycle again.</para></listitem>
<listitem><para>Don't put separate patches in one large diff file. This makes
it harder to read, understand and test the patch. You might
also risk not getting a good patch committed because you mixed it
<listitem><para>Don't put separate patches in one large diff file. This makes
it harder to read, understand and test the patch. You might
also risk not getting a good patch committed because you mixed it
with one that had issues. </para></listitem>
<listitem><para>Make sure your patch complies to the samba coding style as
suggested in the coding-suggestions chapter. </para></listitem>
<listitem><para>Make sure your patch complies to the samba coding style as
suggested in the coding-suggestions chapter. </para></listitem>
</itemizedlist>
</para>
</listitem>
Expand All @@ -79,7 +79,7 @@
<term>Sending in bugfixes</term>
<listitem>
<para>Bugfixes to bugs in samba should be submitted to samba's
<ulink url="https://bugzilla.samba.org/">bugzilla system</ulink>,
<ulink url="https://bugzilla.samba.org/">bugzilla system</ulink>,
along with a description of the bug.
</para>
</listitem>
Expand All @@ -88,22 +88,22 @@
<varlistentry>
<term>Sending in feature patches</term>
<listitem>
<para>Send feature patches along with a description of what the
patch is supposed to do to the
<para>Send feature patches along with a description of what the
patch is supposed to do to the
<ulink url="mailto:[email protected]">Samba-technical mailinglist</ulink> and possibly to a samba team member who is (one of the) 'owners'
of the code you made modifications to. We are all busy people
so everybody tends to 'let one of the others handle it'. If nobody
responded to your patch for a week, try to send it again until you
of the code you made modifications to. We are all busy people
so everybody tends to 'let one of the others handle it'. If nobody
responded to your patch for a week, try to send it again until you
get a response from one of us.
</para></listitem>
</varlistentry>

<varlistentry>
<term>Feedback on your patch</term>
<listitem>
<para>One of the team members will look at your patch and either
commit your patch or give comments why he won't apply it. In the
latter case you can fix your patch and re-send it until
<para>One of the team members will look at your patch and either
commit your patch or give comments why he won't apply it. In the
latter case you can fix your patch and re-send it until
your patch is approved.</para>
</listitem>
</varlistentry>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,7 @@ input is printed into a buffer using the vslprintf() function,
and then passed to format_debug_text().

If you use DEBUGLVL() you will probably print the body of the
message using dbgtext().
message using dbgtext().
</para>
</sect2>

Expand Down
Loading

0 comments on commit cc7ae10

Please sign in to comment.