Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

Anyone got progress on setting null encryption in FreeBSD 8 ipsec?

# ./setkey -c
add 10.10.19.50 10.10.19.100 esp 1680464666 -m transport -E null -A hmac-md5 "authentication!!" ;

The result of line 1: Invalid argument.

patch from here change nothing same error.

share|improve this question

migrated from serverfault.com Nov 22 '13 at 15:53

This question came from our site for professional system and network administrators.

1 Answer 1

Ok. I solved it. Let me show solution just in case someone need it. First You need enable IPSEC in kernel, build install.

In file /src/sbin/setkey/parse.y comment code

enc_alg
        :       ALG_ENC_NOKEY {
                        if ($1 < 0) {
                                yyerror("unsupported algorithm");
                                return -1;
                        }
                        p_alg_enc = $1;

                        p_key_enc_len = 0;
                        p_key_enc = NULL;
                        /*
                        if (ipsec_check_keylen(SADB_EXT_SUPPORTED_ENCRYPT,
                            p_alg_enc, PFKEY_UNUNIT64(p_key_enc_len)) < 0) {
                                yyerror(ipsec_strerror());
                                return -1;
                        }
                        */

run make just in setkey folder. Generated binary will support null encryption.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.