Question: I am going to design a firewall using MATLAB and I need to get Ethernet data like IP, Port and MAC address to write my filter rules.

How do I obtain those?

Answer: 
With your shown samples please try following `awk` code. Written and tested in GNU `awk`.

```bash
awk -v RS='{[^}]*}' '
RT{
  if(!sub(/,/,"&",RT)){ gsub(/^{|}$/,"",RT) }
}
{ ORS=RT }
1
END{ print "" }
'  Input_file

```
Using `sed`

```
$ sed -E 's/\{([[:alpha:]_.]+)}/\1/g' input_file
touch ex00/ft_strdup.c ex04/{ft_convert_base.c,ft_convert_base2.c} ex05/ft_split.c

```