# Bro on macos, magic bug

**URL:** <https://community.zeek.org/t/bro-on-macos-magic-bug/3075>\
**Category:** Zeek\
**Created:** [April 21, 2014, 5:06am UTC](https://community.zeek.org/t/bro-on-macos-magic-bug/3075 "2014-04-21T05:06:15Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Julien\_T](https://avatars.discourse-cdn.com/v4/letter/j/67e7ee/32.png) [@Julien\_T](https://community.zeek.org/u/Julien_T)\
**Post date:** [April 21, 2014, 5:06am UTC](https://community.zeek.org/t/bro-on-macos-magic-bug/3075/1 "2014-04-21T05:06:15Z")

</div>

Hello,

I’m trying to use bro 2.2 on Mac (10.9.2) with macports

but when I try to parse a pcap, I got magic errors:

> > >

$ bro -r

/opt/local/share/bro/magic/animation, 193: Warning: Current entry does not yet have a description for adding a MIME type  
/opt/local/share/bro/magic/animation, 195: Warning: Current entry does not yet have a description for adding a MIME type  
/opt/local/share/bro/magic/animation, 197: Warning: Current entry does not yet have a description for adding a MIME type  
/opt/local/share/bro/magic/animation, 199: Warning: Current entry does not yet have a description for adding a MIME type  
/opt/local/share/bro/magic/animation, 201: Warning: Current entry does not yet have a description for adding a MIME type  
/opt/local/share/bro/magic/animation, 203: Warning: Current entry does not yet have a description for adding a MIME type  
/opt/local/share/bro/magic/animation, 205: Warning: Current entry does not yet have a description for adding a MIME type  
/opt/local/share/bro/magic/animation, 208: Warning: Current entry does not yet have a description for adding a MIME type  
/opt/local/share/bro/magic/archive, 45: Warning: Current entry does not yet have a description for adding a MIME type  
/opt/local/share/bro/magic/cafebabe, 19: Warning: Current entry does not yet have a description for adding a MIME type  
internal error: can’t load magic file /opt/local/share/bro/magic: could not find any valid magic files!  
\<\<\<

Those files are from bro, while macports’ libmagic (5.18) has /opt/local/share/misc/magic.mgc

same if I do  
MAGIC=/opt/local/share/misc/magic.mgc bro -r

as suggested on [http://comments.gmane.org/gmane.comp.security.detection.bro/6225](http://comments.gmane.org/gmane.comp.security.detection.bro/6225)

Improvement with [https://bro-tracker.atlassian.net/browse/BIT-1143](https://bro-tracker.atlassian.net/browse/BIT-1143).

I gave a try to github head and it works as expected, probably because of above change.

So is a fix is expected for 2.2 or 2.3 is sufficiently near release?

Thanks

Julien

---

<div class="post-metadata">

**Author:** ![Siwek\_Jon](https://avatars.discourse-cdn.com/v4/letter/s/90db22/32.png) [@Siwek\_Jon](https://community.zeek.org/u/Siwek_Jon)\
**Post date:** [April 21, 2014, 2:53pm UTC](https://community.zeek.org/t/bro-on-macos-magic-bug/3075/2 "2014-04-21T14:53:25Z")

</div>

> internal error: can't load magic file /opt/local/share/bro/magic: could not find any valid magic files!  
> \<\<\<
> 
> Those files are from bro, while macports' libmagic (5.18) has /opt/local/share/misc/magic.mgc
> 
> same if I do  
> MAGIC=/opt/local/share/misc/magic.mgc bro -r \<pcapfile\>

Try also `BROMAGIC=/opt/local/share/misc/magic.mgc MAGIC=/opt/local/share/misc/magic.mgc bro -r \<pcapfile\>`.

> So is a fix is expected for 2.2 or 2.3 is sufficiently near release?

No 2.2 changes are planned and the 2.3 (beta) isn’t dated, you’ll have to infer from [https://bro-tracker.atlassian.net/issues/?filter=10001](https://bro-tracker.atlassian.net/issues/?filter=10001)

- Jon

---

<div class="post-metadata">

**Author:** ![Julien\_T](https://avatars.discourse-cdn.com/v4/letter/j/67e7ee/32.png) [@Julien\_T](https://community.zeek.org/u/Julien_T)\
**Post date:** [April 22, 2014, 5:23pm UTC](https://community.zeek.org/t/bro-on-macos-magic-bug/3075/3 "2014-04-22T17:23:36Z")

</div>

> Try also `BROMAGIC=/opt/local/share/misc/magic.mgc  
> MAGIC=/opt/local/share/misc/magic.mgc bro -r \<pcapfile\>`.

yes with BROMAGIC, it's working. without environment or only MAGIC, only  
warnings and no output.

> \> So is a fix is expected for 2.2 or 2.3 is sufficiently near release?
> 
> No 2.2 changes are planned and the 2.3 (beta) isn’t dated, you’ll have to  
> infer from [https://bro-tracker.atlassian.net/issues/?filter=10001](https://bro-tracker.atlassian.net/issues/?filter=10001)

ok.

Thanks a lot!  
Cheers,

Julien

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/zeek/original/1X/f09d732bc2cc7c7cc7e35db67cf4e1d5233ce7a7.png) [@system](https://community.zeek.org/u/system)\
**Post date:** [May 6, 2022, 3:41pm UTC](https://community.zeek.org/t/bro-on-macos-magic-bug/3075/4 "2022-05-06T15:41:43Z")

</div>


