Hi Jan,

I know what is going on... If on the manage_agents, you type "i" (even tough it
doesn't give the import option in the menu) it will allow you to import the
authentication keys. The issue is that for the client installs, we set the
"C" macro CLIENT to tweak the menu and some other options...

To solve this problem, before you compile the code for the agent, execute:
"make setagent" and it will set the CLIENT macro correctly.

*Everything else you did was correctly, you just missed the "make setagent"
before the make all.

*I know, this is not documented :) Sorry about that..

Hope it helps.

--
Daniel B. Cid
dcid ( at ) ossec.net

On 10/10/06, Jan-Petter Kruger <[EMAIL PROTECTED]> wrote:

I've been struggling with this all day , and it's time to get some help
I think.

The machines were I want to install ossec does not have any compiler or
build tools on them. I have to build this on another machine and install
ossec as server on one machine, and ossec as agent on others. This is
what I did initially (following the install guide)

[EMAIL PROTECTED] ~]# wget http://www.ossec.net/files/ossec-hids-latest.tar.gz
[EMAIL PROTECTED] ~]# wget http://www.ossec.net/files/ossec-hids-latest_sum.txt
[EMAIL PROTECTED] ~]# cat ossec-hids-latest_sum.txt
MD5 (ossec-hids-latest.tar.gz) = XXXXXXX
SHA1 (ossec-hids-latest.tar.gz) = YYYYYYYY
[EMAIL PROTECTED] ~]# md5sum ossec-hids-latest.tar.gz
MD5 (ossec-hids-latest.tar.gz) = XXXXXXX
[EMAIL PROTECTED] ~]# sha1sum ossec-hids-latest.tar.gz
SHA1 (ossec-hids-latest.tar.gz) = YYYYYYYY


Then I did

# tar -zxvf ossec-hids-*.tar.gz
# cd ossec-hids-*
# cd src
# make all
# make build
# cd ..
# nano etc/preloaded-vars.conf

and set

USER_BINARYINSTALL="x"

Then

# cd ..
# tar -cvzf ossec-hids-0.9-2-binary.tar.gz ossec-hids-0.9-2


Then I transfered the tar file to the machine running the serverversion
and did a server install successfully. Took about 1 minute before I got
the first mail from ossec.

Then I transfered the tar file to a machine where I want to run an
agent, and did an agent install, no error messages. Then I try to do


# /var/ossec/bin/manage_agents
and the dialog displayed is not hte agent dialog I expected, as it is
the same as I get on the server install.

****************************************
* OSSEC HIDS v0.9-2 Agent manager.       *
* The following options are available: *
****************************************
   (A)dd an agent (A).
   (E)xtract key for an agent (E).
   (L)ist already added agents (L).
   (R)emove an agent (R).
   (Q)uit.
Choose your action: A,E,L,R or Q:

So, I've tried different ways of doing the build by using different make
targets to see if anything gets any different, but I'm stuck. Any ideas
to what I should do now to get the mange_agents to recognize its running
on a client install ?

System where I test the agent install

Linux testagent 2.6.16-xen #1 SMP Thu Apr 13 18:46:07 BST 2006 i686
GNU/Linux

Jan-Petter ::-Q

Reply via email to