Hi Anand,

strongswan uses standard libc printf hooks if they are available.
Otherwise vstr is used to emulate printf hooks. The strongSwan
printf_hook_t framework is defined here:


E.g. the printf_hook handler for %N (printing of enum_name_t types) is
defined here:


and the all hooks used by libstrongswan are assigned here:


Hope this helps


On 13.01.2017 13:46, Anand Murali wrote:

I have been going through the source code of strongswan.

I came across lots of custom format specifiers like:

DBG1(DBG_ENC, "U_INT Type *%N* is not supported",
encoding_type_names, int_type);

DBG2(DBG_CFG, "received proposals: *%#P*", proposals);

I'm new to this. Have been going through this code for a week. I'm not
able to figure out how these are evaluated.

Any help to understand how these are evaluated?

If there is an internal code that does this parsing, can you point me to
that file?

Andreas Steffen                         andreas.stef...@strongswan.org
strongSwan - the Open Source VPN Solution!          www.strongswan.org
Institute for Internet Technologies and Applications
University of Applied Sciences Rapperswil
CH-8640 Rapperswil (Switzerland)

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature

Dev mailing list

Reply via email to