Adds IPv6 support for the tcsd

	Server will now bind in two ports: one for tcp and one
	for tcp6. It only will fail if both protocol fails.

	Signed-off-by: Richard Maciel <rmaciel@linux.vnet.ibm.com>
	Acked-by: Joel Schopp <jschopp@linux.vnet.ibm.com>
Added disable_ipv4 and disable_ipv6 config options

These new configuration options will provide information for tcsd
related to IP protocol usage. Former indicates that the daemon
must not bind itself to IPv4 local addresses, while the latter
refer to IPv6 local addresses.

Signed-off-by: Richard Maciel <rmaciel@linux.vnet.ibm.com>
Acked-by: Joel Schopp <jschopp@linux.vnet.ibm.com>
Link new options to daemon code

disable_ipv4 and disable_ipv6 controls the creation of IPv4 and IPv6
sockets, respectively.

Signed-off-by: Richard Maciel <rmaciel@linux.vnet.ibm.com>
Acked-by: Joel Schopp <jschopp@linux.vnet.ibm.com>
Add functions to fetch hostname and port info to clients

Modules included will be used by the next modifications to
retrieve hostname and port information to setup client
connections to the tcsd.

Signed-off-by: Richard Maciel <rmaciel@linux.vnet.ibm.com>
Acked-by: Joel Schopp <jschopp@linux.vnet.ibm.com>
New socket creation code to RPC calls

This code provides underlying sockets to the RPC calls.
It was remade to use the new function that gather port information and
to use new API to retrieve hostname data.

Signed-off-by: Richard Maciel <rmaciel@linux.vnet.ibm.com>
Acked-by: Joel Schopp <jschopp@linux.vnet.ibm.com>
New code to retrieve hostname to object contexts

This code uses the provided get_tcsd_hostname to retrieve hostname
information on the tcsd.

Signed-off-by: Richard Maciel <rmaciel@linux.vnet.ibm.com>
Acked-by: Joel Schopp <jschopp@linux.vnet.ibm.com>
Fix access control function

access_control function for the server is able to handle addresses
generated by the get_tcsd_hostname function.

Signed-off-by: Richard Maciel <rmaciel@linux.vnet.ibm.com>
Acked-by: Joel Schopp <jschopp@linux.vnet.ibm.com>
Fixes warning msgs introduced by recent patch set

Patchset named "Changed underlying network code to better
support IPv6" (starts with commit
982c3ebe9d9a00284650a8745d3e8fb912f3d307 and ends with commit
5656124f3b873d233a9818efa4490866c7726a19) introduced three warning
messages. Two related to prototypes of new functions not being
declared in their header file and one related to a missing
typecast.

Signed-off-by: Richard Maciel <rmaciel@linux.vnet.ibm.com>
Acked-by: Joel Schopp <jschopp@linux.vnet.ibm.com>
Bump version to 0.3.12
Add support for running tcsd as non TSS:TSS user+group.

When developing with tcsd it is currently required to create the user/group
TSS:TSS since tcsd will switch to it and check that config and state files
are owned by it. This can be troublesome in development environments where
you want to run tcsd as a user and not mess with global system settings.

Add configure switch --disable-usercheck for disable the TSS:TSS need of tcsd:
- No tcsd.conf and /var/lib/tpm owner-checking
- No switching to user by tcsd
- No useradd/groupadd and userdel/groupdel
- No chowns and chmods
- Warning at start of tcsd about this behaviour

Signed-off-by: Andreas Fuchs <andreas.fuchs@sit.fraunhofer.de>
Acked-by: Joel Schopp <jschopp@linux.vnet.ibm.com>
Tested-by: Richard Maciel <rmaciel@linux.vnet.ibm.com>