# An Embedded pfsense-like distribution



## nosferatu (Jul 19, 2017)

Hello,

I want to create a mini-distribution for MIPS or ARM based low-RAM low-ROM devices based on FreeBSD. It will be like pfsense. I will provide a way people to use FreeBSD's features without knowing much about FreeBSD. Still they will be able to reach the command line if they want to.

But first I need to read the source code and the user manual. Where should I start? Kernel?

Plans:
-Use geom_uzip file-system. And a minimal file-system for ports that can be installed later.
-Fork existing BSDBox in progress and code the rest after I finish reading, if the release is not come by then.
-Use LibreSSL and OpenSSH and not to use Dropbear and OpenSSL.
-No IPTables, no ipfw, just PF.
-Precompiled packages. Download and install. May be compiled and added to geom_uzip if know-how.
-Will build with this flags: https://forums.freebsd.org/threads/15969/#post-92975 or maybe some extra without flags.
-lua language for web interface. i will learn it.
-In the future replace FreeBSD C library with minimalist subset. BSD Licenced.

Questions:
-The first one above: Should I read source code and if I do where to start?
-Do I need BIND or Named? Or can build without this to and have internet access?
-Is it more reasonable to use Busybox instead of coding rest of the BSDBox if it is not finished.
-Any suggestions about this work?
-What should I used for editable rootfs? UFS or is there a more minimal choice?

Edit: My fundraiser: https://www.generosity.com/communit...d-embedded-os-for-mips-arm-routers/x/17038278 Would you please share it?


----------



## nosferatu (Jul 19, 2017)

Phishfry said:


> This runs on several architectures. Have you tried it yet?
> https://bsdrp.net/BSDRP



MIPS and ARM is the key here. https://bsdrp.net/documentation/faq...a_mips_or_arm_device_routerstation_d-link_etc Unfortunately this runs on x86 only. But i will check out Bird and FRRouting.

Edit: I checked FRR and Bird out. They are GPL so they are no-go for me. I want BSD/Apache/MIT like licences in it. I don't want Busybox because of that too.

A correction: When I said embedded I mean Home Routers and APs.

Edit there is Zrouter but it is dead. I can take some code from it if I can find the source code.


----------



## Jov (Jul 20, 2017)

Maybe you can start with freebsd-wifi-build project: https://github.com/freebsd/freebsd-wifi-build
This is a project similar with openwrt， mainly for mips router with small storage like 8MB/16MB. It already supports some popular route boards, detail on the wiki: https://github.com/freebsd/freebsd-wifi-build/wiki.

For arm, you can look https://github.com/freebsd/crochet project.


----------



## nosferatu (Jul 20, 2017)

Jov said:


> Maybe you can start with freebsd-wifi-build project...
> 
> ...For arm, you can look crochet project.



Thank you. I am aware of the freebsd-wifi-build project. It uses BusyBox, iptables, ipfw and not pf. But I will dig into its source code when building images.

I did not know the crochet project. I will look into it.

Thank you again.

Edit: My fundraiser: https://www.generosity.com/communit...d-embedded-os-for-mips-arm-routers/x/17038278


----------



## nosferatu (Jul 22, 2017)

OK. I found the book to read. To anyone who is interested it is: Design and Implementation of the FreeBSD Operating System, The 2nd Edition


----------

