Firefox cookies are stored in sqlite database.
in ubuntu the cookies are locate in /home/username/.mozilla/firefox/random.default/cookies.sqlite
to locate the cookies.sqlite just type
locate cookies.sqlite
To read the cookies we need to install sqlite3.
To install it in ubuntu/debian
sudo apt-get install sqlite3
open the cookies with sqlite3
sqlite3 /home/username/.mozilla/firefox/random.default/cookies.sqlite
after you have opened the db type
select * from moz_cookies;
to show mozilla firefox cookies.
if you want to export them type
.output mozilla_cookies.txt
select * from moz_cookies;