Modify

Opened 12 years ago

Closed 11 years ago

Last modified 4 years ago

#444 closed defect (fixed)

busybox:awk problem with openswan's ipsec showhostkey

Reported by: ewb Owned by: florian
Priority: low Milestone: Barrier Breaker 14.07
Component: packages Version:
Keywords: openswan xregcomp Cc:

Description

Many discussions were found on this issue, but no solution has been mentioned yet.

Busybox's awk has trouble with openswan's showhostkey script. The 'ipsec showhostkey ...' commands report the following output:
# ipsec showhostkey --left
awk: xregcomp: Invalid content of \{\}

To correct this issue, replace the occurance of "{" with "\0173" in the awk script inside of /usr/libexec/ipsec/showhostkey:
< suffix = ":" os "[rR][sS][aA]" os "{" os oc "$"

suffix = ":" os "[rR][sS][aA]" os "\0173" os oc "$"

Attachments (0)

Change History (8)

comment:1 Changed 12 years ago by florian

  • Owner changed from developers to florian
  • Status changed from new to assigned

comment:2 Changed 12 years ago by florian

  • Milestone set to 2.0
  • Priority changed from normal to low

comment:3 Changed 11 years ago by florian

  • Resolution set to fixed
  • Status changed from assigned to closed

Fixed in [4632]

comment:4 Changed 11 years ago by Durval Menezes <durval AT tmp DOT com DOT br>

The aforementioned modification (replacing "{" by "\0173") eliminated the error message but made showhostkey always return the message 'ipsec showhostkey: no default key in "/etc/ipsec.secrets"'; some debugging showed me that "\0173" expands to the two characters "\017" (SI) and "3", that is, the regexp never matches. The proper way to represent "{" in octal is "\173" (three digits) which incidentally does not work; after some trial and error I found that replacing "{" by "[{]" fixes the problem completely.

comment:5 Changed 11 years ago by Durval Menezes <durval AT tmp DOT com DOT br>

  • Resolution fixed deleted
  • Status changed from closed to reopened

Reopening ticket so as to bring it to the attention of the developers

BTW, here's the diff of my solution:

--- /usr/libexec/ipsec/showhostkey.orig-20061105 2006-11-06 00:29:11.000000000 -0200
+++ /usr/libexec/ipsec/showhostkey 2006-11-06 00:29:11.000000000 -0200
@@ -81,7 +81,7 @@

os = "[ \t]*"
x = "[ \t]+"
oc = "(#.*)?"

  • suffix = ":" os "[rR][sS][aA]" os "{" os oc "$"

+ suffix = ":" os "[rR][sS][aA]" os "[{]" os oc "$";

if (id == "") {

pat = "" suffix
printid = "default"

comment:6 Changed 11 years ago by florian

  • Status changed from reopened to new

Please use the WikiFormatting syntax, I don't understand a word of your patch.

comment:7 Changed 11 years ago by florian

  • Resolution set to fixed
  • Status changed from new to closed

Fixed in [5538]

comment:8 Changed 4 years ago by jow

  • Milestone changed from Attitude Adjustment 12.09 to Barrier Breaker 14.07

Milestone Attitude Adjustment 12.09 deleted

Add Comment

Modify Ticket

Action
as closed .
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.