<div dir="ltr"><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default">Hi,</div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default"><br></div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default">I would like to harden the security by enabling authentication between syslog-ng and MongoDB. <br></div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default"><br></div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default">I'm using syslog-ng v3.38 and MongoDB v6.0.8</div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default"><br></div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default">At the destination I tried the below two methods but none of themt worked, am I doing something wrong? Or the authentication is not supported?<br></div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default"><br></div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default"><u>---> First method:</u><br></div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default">destination d_mongodb_01 {<br>mongodb(<br>uri("mongodb://<a href="http://SampleUser:SamplePass@172.16.17.16:27017/syslog-ng_01">SampleUser:SamplePass@172.16.17.16:27017/syslog-ng_01</a>")<br>collection("logs")<br>value-pairs(<br>pair("datetime" "${S_ISODATE}")<br>pair("privateip" "${privateip}")<br>pair("portstatus" "${PORTSTATUS}")<br>pair("host" "${HOST}"))<br>);<br>};</div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default"><br></div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default">
<u>---> Second method:</u>

</div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default">
<div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default">destination d_mongodb_01 {<br>mongodb(<br>uri("mongodb://<a href="http://172.16.17.16:27017/syslog-ng_01">172.16.17.16:27017/syslog-ng_01</a>")</div>username("SampleUser")</div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default">password("SamplePass")<br></div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default"><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default">collection("logs")<br>value-pairs(<br>pair("datetime" "${S_ISODATE}")<br>pair("privateip" "${privateip}")<br>pair("portstatus" "${PORTSTATUS}")<br>pair("host" "${HOST}"))<br>);<br>};</div>

</div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default"><br></div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default">Appreciate your help<br></div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default"><br></div><div style="font-family:tahoma,sans-serif;color:rgb(7,55,99)" class="gmail_default">Best regards <br></div><br></div>