{"id":105,"date":"2005-03-07T04:57:53","date_gmt":"2005-03-07T01:57:53","guid":{"rendered":"http:\/\/void.gr\/kargig\/blog\/?p=105"},"modified":"2005-03-31T16:34:50","modified_gmt":"2005-03-31T13:34:50","slug":"encrypting-the-swap-partition","status":"publish","type":"post","link":"https:\/\/www.void.gr\/kargig\/blog\/2005\/03\/07\/encrypting-the-swap-partition\/","title":{"rendered":"Encrypting the swap partition"},"content":{"rendered":"<p>Now that my system is considered (that&#8217;s what I think) a working desktop machine, it&#8217;s time for some security. First and easiest thing to do is to encrypt the swap partition.<br \/>\nWhat should I use though to achieve this goal ? cryptoloop ? Loop-AES ? cgd ? ppdd ? and so on and so on&#8230;The choices are too many to list. After reading Loop-AES author&#8217;s reply to this question:<\/p>\n<blockquote><p>\n[&#8230;] if Loop-AES works so much better, why hasn&#8217;t it been included in the kernel?[&#8230;]\n<\/p><\/blockquote>\n<p><a href=\"http:\/\/http:\/\/www.uwsg.iu.edu\/hypermail\/linux\/kernel\/0402.2\/1137.html\">here<\/a>, and studying this great guide on computer security (<a href=\"http:\/\/jdoedoe.tripod.com\/\">How to defend your Privacy<\/a>), I&#8217;ve decided to go for Loop-AES.<\/p>\n<p>Quick SWAP encryption with Loop-AES HOWTO for gentoo linux:<\/p>\n<p>1)Be SURE to remove any loop support from your kernel. Either as a module or builtin. We are going to build our own module so we don&#8217;t want the kernel&#8217;s module. <\/p>\n<p>2) Supposing that your kernel does NOT have loop support we move on to installing the necessary packages.<br \/>\n<code><br \/>\necho \"sys-fs\/loop-aes ~x86\" >> \/etc\/portage\/package.keywords<br \/>\nemerge \/usr\/portage\/sys-apps\/util-linux\/util-linux-2.12q.ebuild<br \/>\nemerge loop-aes<br \/>\n<\/code><\/p>\n<p>3) Time to change current swap configuration end enable the encryption support<br \/>\n<code><br \/>\nswapoff -a<br \/>\n<\/code><br \/>\nNow edit your \/etc\/fstab, find your swap lines and change them to something looking like this:<br \/>\n<code><br \/>\n \/dev\/hda999   none   swap   sw,loop=\/dev\/loop9,encryption=AES128   0   0<br \/>\n<\/code><\/p>\n<p>4) We now clean the swap partition by filling it with 0s, recreate the swap partition and start using it<br \/>\n<code><br \/>\ndd if=\/dev\/zero of=\/dev\/hda999 bs=64k conv=notrunc<br \/>\nmkswap \/dev\/hda999<br \/>\nswapon -a<br \/>\n<\/code><\/p>\n<p>You are ready, you swap is now encrypted on the fly.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Now that my system is considered (that&#8217;s what I think) a working desktop machine, it&#8217;s time for some security. First and easiest thing to do is to encrypt the swap partition. What should I use though to achieve this goal ? cryptoloop ? Loop-AES ? cgd ? ppdd ? and so on and so on&#8230;The [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"ep_exclude_from_search":false,"footnotes":""},"categories":[1,3],"tags":[],"class_list":["post-105","post","type-post","status-publish","format-standard","hentry","category-general","category-linux"],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 5.0.3 - aioseo.com -->\n\t<meta name=\"description\" content=\"Now that my system is considered (that&#039;s what I think) a working desktop machine, it&#039;s time for some security. First and easiest thing to do is to encrypt the swap partition. What should I use though to achieve this goal ? cryptoloop ? Loop-AES ? cgd ? ppdd ? and so on and so on...The\" \/>\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"kargig\"\/>\n\t<link rel=\"canonical\" href=\"https:\/\/www.void.gr\/kargig\/blog\/2005\/03\/07\/encrypting-the-swap-partition\/\" \/>\n\t\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 5.0.3\" \/>\n\t\t<script type=\"application\/ld+json\" class=\"aioseo-schema\">\n\t\t\t{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/2005\\\/03\\\/07\\\/encrypting-the-swap-partition\\\/#article\",\"name\":\"Encrypting the swap partition | Into.the.Void.\",\"headline\":\"Encrypting the swap partition\",\"author\":{\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/author\\\/site-admin\\\/#author\"},\"publisher\":{\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/#organization\"},\"datePublished\":\"2005-03-07T04:57:53+02:00\",\"dateModified\":\"2005-03-31T16:34:50+03:00\",\"inLanguage\":\"en-US\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/2005\\\/03\\\/07\\\/encrypting-the-swap-partition\\\/#webpage\"},\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/2005\\\/03\\\/07\\\/encrypting-the-swap-partition\\\/#webpage\"},\"articleSection\":\"General, Linux\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/2005\\\/03\\\/07\\\/encrypting-the-swap-partition\\\/#breadcrumblist\",\"itemListElement\":[{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/#listItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/category\\\/general\\\/#listItem\",\"name\":\"General\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/category\\\/general\\\/#listItem\",\"position\":2,\"name\":\"General\",\"item\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/category\\\/general\\\/\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/2005\\\/03\\\/07\\\/encrypting-the-swap-partition\\\/#listItem\",\"name\":\"Encrypting the swap partition\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/#listItem\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/2005\\\/03\\\/07\\\/encrypting-the-swap-partition\\\/#listItem\",\"position\":3,\"name\":\"Encrypting the swap partition\",\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/category\\\/general\\\/#listItem\",\"name\":\"General\"}}]},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/#organization\",\"name\":\"Into.the.Void.\",\"description\":\"Into The Void\",\"url\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/\",\"sameAs\":[\"https:\\\/\\\/x.com\\\/kargig\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/author\\\/site-admin\\\/#author\",\"url\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/author\\\/site-admin\\\/\",\"name\":\"kargig\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/2005\\\/03\\\/07\\\/encrypting-the-swap-partition\\\/#webpage\",\"url\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/2005\\\/03\\\/07\\\/encrypting-the-swap-partition\\\/\",\"name\":\"Encrypting the swap partition | Into.the.Void.\",\"description\":\"Now that my system is considered (that's what I think) a working desktop machine, it's time for some security. First and easiest thing to do is to encrypt the swap partition. What should I use though to achieve this goal ? cryptoloop ? Loop-AES ? cgd ? ppdd ? and so on and so on...The\",\"inLanguage\":\"en-US\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/#website\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/2005\\\/03\\\/07\\\/encrypting-the-swap-partition\\\/#breadcrumblist\"},\"author\":{\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/author\\\/site-admin\\\/#author\"},\"creator\":{\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/author\\\/site-admin\\\/#author\"},\"datePublished\":\"2005-03-07T04:57:53+02:00\",\"dateModified\":\"2005-03-31T16:34:50+03:00\"},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/\",\"name\":\"Into.the.Void.\",\"description\":\"Into The Void\",\"inLanguage\":\"en-US\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.void.gr\\\/kargig\\\/blog\\\/#organization\"}}]}\n\t\t<\/script>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"Encrypting the swap partition | Into.the.Void.","description":"Now that my system is considered (that's what I think) a working desktop machine, it's time for some security. First and easiest thing to do is to encrypt the swap partition. What should I use though to achieve this goal ? cryptoloop ? Loop-AES ? cgd ? ppdd ? and so on and so on...The","canonical_url":"https:\/\/www.void.gr\/kargig\/blog\/2005\/03\/07\/encrypting-the-swap-partition\/","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.void.gr\/kargig\/blog\/2005\/03\/07\/encrypting-the-swap-partition\/#article","name":"Encrypting the swap partition | Into.the.Void.","headline":"Encrypting the swap partition","author":{"@id":"https:\/\/www.void.gr\/kargig\/blog\/author\/site-admin\/#author"},"publisher":{"@id":"https:\/\/www.void.gr\/kargig\/blog\/#organization"},"datePublished":"2005-03-07T04:57:53+02:00","dateModified":"2005-03-31T16:34:50+03:00","inLanguage":"en-US","mainEntityOfPage":{"@id":"https:\/\/www.void.gr\/kargig\/blog\/2005\/03\/07\/encrypting-the-swap-partition\/#webpage"},"isPartOf":{"@id":"https:\/\/www.void.gr\/kargig\/blog\/2005\/03\/07\/encrypting-the-swap-partition\/#webpage"},"articleSection":"General, Linux"},{"@type":"BreadcrumbList","@id":"https:\/\/www.void.gr\/kargig\/blog\/2005\/03\/07\/encrypting-the-swap-partition\/#breadcrumblist","itemListElement":[{"@type":"ListItem","@id":"https:\/\/www.void.gr\/kargig\/blog\/#listItem","position":1,"name":"Home","item":"https:\/\/www.void.gr\/kargig\/blog\/","nextItem":{"@type":"ListItem","@id":"https:\/\/www.void.gr\/kargig\/blog\/category\/general\/#listItem","name":"General"}},{"@type":"ListItem","@id":"https:\/\/www.void.gr\/kargig\/blog\/category\/general\/#listItem","position":2,"name":"General","item":"https:\/\/www.void.gr\/kargig\/blog\/category\/general\/","nextItem":{"@type":"ListItem","@id":"https:\/\/www.void.gr\/kargig\/blog\/2005\/03\/07\/encrypting-the-swap-partition\/#listItem","name":"Encrypting the swap partition"},"previousItem":{"@type":"ListItem","@id":"https:\/\/www.void.gr\/kargig\/blog\/#listItem","name":"Home"}},{"@type":"ListItem","@id":"https:\/\/www.void.gr\/kargig\/blog\/2005\/03\/07\/encrypting-the-swap-partition\/#listItem","position":3,"name":"Encrypting the swap partition","previousItem":{"@type":"ListItem","@id":"https:\/\/www.void.gr\/kargig\/blog\/category\/general\/#listItem","name":"General"}}]},{"@type":"Organization","@id":"https:\/\/www.void.gr\/kargig\/blog\/#organization","name":"Into.the.Void.","description":"Into The Void","url":"https:\/\/www.void.gr\/kargig\/blog\/","sameAs":["https:\/\/x.com\/kargig"]},{"@type":"Person","@id":"https:\/\/www.void.gr\/kargig\/blog\/author\/site-admin\/#author","url":"https:\/\/www.void.gr\/kargig\/blog\/author\/site-admin\/","name":"kargig"},{"@type":"WebPage","@id":"https:\/\/www.void.gr\/kargig\/blog\/2005\/03\/07\/encrypting-the-swap-partition\/#webpage","url":"https:\/\/www.void.gr\/kargig\/blog\/2005\/03\/07\/encrypting-the-swap-partition\/","name":"Encrypting the swap partition | Into.the.Void.","description":"Now that my system is considered (that's what I think) a working desktop machine, it's time for some security. First and easiest thing to do is to encrypt the swap partition. What should I use though to achieve this goal ? cryptoloop ? Loop-AES ? cgd ? ppdd ? and so on and so on...The","inLanguage":"en-US","isPartOf":{"@id":"https:\/\/www.void.gr\/kargig\/blog\/#website"},"breadcrumb":{"@id":"https:\/\/www.void.gr\/kargig\/blog\/2005\/03\/07\/encrypting-the-swap-partition\/#breadcrumblist"},"author":{"@id":"https:\/\/www.void.gr\/kargig\/blog\/author\/site-admin\/#author"},"creator":{"@id":"https:\/\/www.void.gr\/kargig\/blog\/author\/site-admin\/#author"},"datePublished":"2005-03-07T04:57:53+02:00","dateModified":"2005-03-31T16:34:50+03:00"},{"@type":"WebSite","@id":"https:\/\/www.void.gr\/kargig\/blog\/#website","url":"https:\/\/www.void.gr\/kargig\/blog\/","name":"Into.the.Void.","description":"Into The Void","inLanguage":"en-US","publisher":{"@id":"https:\/\/www.void.gr\/kargig\/blog\/#organization"}}]}},"aioseo_meta_data":{"post_id":"105","title":null,"description":null,"keywords":null,"keyphrases":null,"primary_term":null,"canonical_url":null,"og_title":null,"og_description":null,"og_object_type":"default","og_image_type":"default","og_image_url":null,"og_image_width":null,"og_image_height":null,"og_image_custom_url":null,"og_image_custom_fields":null,"og_video":null,"og_custom_url":null,"og_article_section":null,"og_article_tags":null,"twitter_use_og":false,"twitter_card":"default","twitter_image_type":"default","twitter_image_url":null,"twitter_image_custom_url":null,"twitter_image_custom_fields":null,"twitter_title":null,"twitter_description":null,"schema":{"blockGraphs":[],"customGraphs":[],"default":{"data":{"Article":[],"Course":[],"Dataset":[],"FAQPage":[],"Movie":[],"Person":[],"Product":[],"ProductReview":[],"Car":[],"Recipe":[],"Service":[],"SoftwareApplication":[],"WebPage":[]},"graphName":"Article","isEnabled":true},"graphs":[]},"schema_type":"default","schema_type_options":null,"pillar_content":false,"robots_default":true,"robots_noindex":false,"robots_noarchive":false,"robots_nosnippet":false,"robots_nofollow":false,"robots_noimageindex":false,"robots_noodp":false,"robots_notranslate":false,"robots_max_snippet":null,"robots_max_videopreview":null,"robots_max_imagepreview":"large","priority":null,"frequency":null,"local_seo":null,"limit_modified_date":false,"created":"2022-01-04 12:02:20","updated":"2026-10-21 09:06:45","focus_keyword":null,"additional_keywords":null,"truseo_locale":null,"ai":null,"breadcrumb_settings":null,"seo_analyzer_scan_date":null},"aioseo_breadcrumb":"<div class=\"aioseo-breadcrumbs\"><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/www.void.gr\/kargig\/blog\/\" title=\"Home\">Home<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">\u00bb<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/www.void.gr\/kargig\/blog\/category\/general\/\" title=\"General\">General<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">\u00bb<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\tEncrypting the swap partition\n\t\t<\/span><\/div>","aioseo_breadcrumb_json":[{"label":"Home","link":"https:\/\/www.void.gr\/kargig\/blog\/"},{"label":"General","link":"https:\/\/www.void.gr\/kargig\/blog\/category\/general\/"},{"label":"Encrypting the swap partition","link":"https:\/\/www.void.gr\/kargig\/blog\/2005\/03\/07\/encrypting-the-swap-partition\/"}],"views":3078,"_links":{"self":[{"href":"https:\/\/www.void.gr\/kargig\/blog\/wp-json\/wp\/v2\/posts\/105","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.void.gr\/kargig\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.void.gr\/kargig\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.void.gr\/kargig\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.void.gr\/kargig\/blog\/wp-json\/wp\/v2\/comments?post=105"}],"version-history":[{"count":0,"href":"https:\/\/www.void.gr\/kargig\/blog\/wp-json\/wp\/v2\/posts\/105\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.void.gr\/kargig\/blog\/wp-json\/wp\/v2\/media?parent=105"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.void.gr\/kargig\/blog\/wp-json\/wp\/v2\/categories?post=105"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.void.gr\/kargig\/blog\/wp-json\/wp\/v2\/tags?post=105"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}