Knowledge

Apache SpamAssassin: Difference between revisions

Source 📝

414: 1745: 641:. Within this file, they can specify individuals whose emails are never considered spam, or change the scores for certain rules. The user can also define a list of languages which they want to receive mail in, and SpamAssassin then assigns a higher score to all mails that appear to be written in another language. This can be very useful to users receiving a lot of foreign spam but never actually corresponding with people in that language. 71: 613:"limited time only" phrase) might be assigned a score of +0.3. With a spam threshold of 5 (default as of SpamAssassin version 2.55), several other tests would usually have to fail for the mail to be classified as spam. On the other hand, some tests, such as those for invalid message IDs or years, result in a very high score being assigned, where even a single test can almost put a mail "over the edge". 617: 501:
used in conjunction with the sources of spam may far exceed the average user's capability. For instance, graphic-only spam messages have no text to compare to therefore checking the sender's originating mailserver and included links against various databases of known e-mail abusers enables the prevention of unnecessary or non-personal mail getting through to the end user.
609:, and if these expressions match, the email is assigned a certain score, depending on the test, and several (customizable) headers are added to the mail. The total score resulting from all tests or other criteria can then be used by the end user or by the ISP to set the conditions under which email is moved to a separate spam folder, deleted, flagged etc. 633:
attachment, with a brief excerpt in the message body, and a description of the tests which resulted in the mail being classified as spam. If the score is lower than the defined settings, by default the information about the passed tests and total score is still added to the email headers and can be
500:
as one of the most effective spam filters, especially when used in combination with spam databases. While simple text-matching alone may, for most users, be sufficient to correctly classify a majority of incoming mail the complexity involved in the combination of the comparison of words and symbols
612:
Each test has a label and a description. The label is usually an all upper case identifier separated with underscores, such as "LIMITED_TIME_ONLY", with the description for that label being "Offers a limited time offer". A mail that fails that test (in this case, contains certain variants of the
720:
can be called for individual emails. Regardless of the method used to perform the learning, SpamAssassin's Bayesian test will subsequently assign a higher score to e-mails that are similar to previously received spam (or, more precisely, to those emails that are different from
159: 63: 628:
When a mail's total score is higher than the "required_score" setting in SpamAssassin's configuration, the mail is treated as spam and rewritten according to several options. In the default configuration, the content of the mail is appended as a
604:
SpamAssassin comes with a large set of rules which are applied to determine whether an email is spam or not. To decide, specific fields within the email header and the email body are typically searched for certain
15: 1781: 1771: 208: 142: 779:
test file. If this string is inserted in a RFC 2822 formatted message and passed through the SpamAssassin engine, SpamAssassin will trigger with a weight of 1000.
705:
example "ham" (useful) mails to the filter, which can then learn the difference between the two. For this purpose, SpamAssassin provides the command-line tool
925: 670: 510: 851: 154: 93: 827: 31: 28: 1578: 72: 918: 752: 573:). The latter mode of operation has performance benefits, but under certain circumstances may introduce additional security risks. 879: 355: 701:, but Bayesian learning is most effective with actual user input. Typically, the user is expected to "feed" example spam mails 150: 89: 184: 118: 1749: 911: 666: 716:
on the folder of non-spam and on the folder of spam separately. Alternatively, if the mail user agent supports it,
436: 338: 934: 1521: 486: 177: 111: 389: 497: 366: 746: 566: 493:-based, checksum-based and statistical filtering, supported by external programs and online databases. 166: 100: 1526: 1000: 680: 553:) which is usually used to filter all incoming mail for one or several users. It can be run as a 897: 250:* showing that SpamAssassin received 69% of the vote for "best Linux-based anti-spam solution." 243:* showing that SpamAssassin received 69% of the vote for "best Linux-based anti-spam solution." 1776: 1541: 712:
Typically, the user will move unrecognized spam to a separate folder for a while, and then run
554: 1465: 900:
showing that SpamAssassin received 69% of the vote for "best Linux-based anti-spam solution."
709:, which can be instructed to learn a single mail or an entire mailbox as either ham or spam. 66: 760: 854:
is a hosted spam and virus solution that uses SpamAssassin as part of the filtering process
521:. Mason rewrote all of Jeftovic's code from scratch and uploaded the resulting codebase to 8: 634:
used in post-processing for less severe actions, such as tagging the mail as suspicious.
413: 689:
More methods can be added reasonably easily by writing a Perl plug-in for SpamAssassin.
995: 698: 606: 558: 490: 1420: 1310: 1195: 1060: 1045: 1025: 173: 107: 1629: 1503: 1460: 1450: 1150: 1110: 1095: 1050: 874: 845: 742: 621: 589: 475: 448: 424: 16: 1664: 1659: 1639: 1495: 1475: 1435: 1430: 1425: 1410: 1365: 1140: 1030: 960: 955: 950: 903: 848:
uses SpamEliminator, which is based on SpamAssassin, for heuristic spam filtering
776: 581: 1730: 1704: 1699: 1654: 1614: 1557: 1531: 1513: 1330: 1325: 1305: 1300: 1295: 1255: 1180: 1075: 1070: 1055: 1035: 965: 800:- email/groupware server contains built-in support for SpamAssassin integration 738: 638: 479: 453: 429: 398: 1765: 1689: 1644: 1619: 1490: 1480: 1455: 1440: 1415: 1360: 1320: 1260: 1235: 1230: 1210: 1190: 1185: 1160: 1145: 1080: 1065: 975: 970: 584:
that supports this, whenever new mail arrives. Mail filter programs such as
47: 1684: 1669: 1624: 1573: 1536: 1485: 1400: 1395: 1385: 1380: 1375: 1370: 1350: 1345: 1290: 1285: 1275: 1240: 1225: 1215: 1200: 1170: 1165: 1130: 1125: 1115: 1105: 1100: 1090: 1040: 1015: 990: 985: 812:
supports SpamAssassin and other spam filters, through some modular filters.
1709: 1649: 1604: 1445: 1390: 1355: 1265: 1245: 1220: 1205: 1175: 1155: 1120: 1020: 1010: 1005: 803: 789: 734: 577: 522: 483: 441: 373: 869: 637:
The user can customize these filters using a file "user_prefs" in their
513:
who had maintained a number of patches against an earlier program named
1714: 1674: 1634: 1583: 1340: 1335: 1315: 1135: 1085: 980: 815: 797: 350: 822:
SpamAssassin has also been used in many commercial products including:
756: 891: 592:
all incoming mail through SpamAssassin with an adjustment to user's
290:* If a spam email MENTIONS a known-bad ], it gets blacklisted by ]. 1270: 1250: 864: 675: 585: 576:
Typically either variant of the application is set up in a generic
526: 463: 234:* to automatically update SA with the newest and best SARE rules. 227:* to automatically update SA with the newest and best SARE rules. 697:
SpamAssassin by default tries to reinforce its own rules through
885: 894:
to automatically update SA with the newest and best SARE rules.
833: 1694: 1609: 1588: 1280: 809: 772: 659: 653: 616: 1679: 1470: 630: 550: 542: 530: 518: 377: 771:
Most implementations of SpamAssassin will trigger on the
620:
E-mail recognized as spam by SpamAssassin, here in the
888:
containing many very good rules for filtering with SA.
725:
in ways similar to previously received spam e-mails).
54: 489:
based on content-matching rules, which also supports
741:. Versions prior to 3.0 are dual-licensed under the 517:
by Mark Jeftovic, which in turn was begun in August
933: 644: 1763: 728: 919: 892:OpenProtect's SpamAssassin sa-update channel 775:, a 68 byte string not unlike the antivirus 337: 926: 912: 806:- "A Free Anti-Virus and Anti-Spam Filter" 412: 580:program, or it is called directly from a 836:uses SpamAssassin in its anti-spam tool 615: 792:products have support for SpamAssassin: 766: 599: 1764: 761:with the trademark holder's permission 686:as a means to tell 'ham' from 'spam'. 662:or URIBL.com which track spam websites 907: 842:Spamnix is also based on SpamAssassin 692: 80: 46: 667:Distributed Checksum Clearinghouses 665:checksum-based filters such as the 536: 327:Revision as of 23:00, 22 March 2007 207: 200: 196: 165: 151:Revision as of 23:00, 22 March 2007 148: 141: 134: 130: 99: 90:Revision as of 22:59, 22 March 2007 87: 13: 886:SpamAssassin Rules Emporium (SARE) 329: 35: 1793: 858: 1744: 1743: 339: 645:Network-based filtering methods 935:The Apache Software Foundation 865:SpamAssassin official homepage 753:Like many open-source programs 1: 755:, the name "SpamAssassin" is 729:Licensing and usage elsewhere 325: 286: 275: 264: 255: 649:SpamAssassin also supports: 509:SpamAssassin was created by 18:Browse history interactively 7: 898:Linux New Media Awards 2006 782: 565:) that communicates with a 10: 1798: 747:GNU General Public License 504: 478:released freely under the 198: 132: 1739: 1723: 1597: 1566: 1550: 1512: 941: 882:Automatically updating SA 830:incorporates SpamAssassin 654:DNS-based blackhole lists 459: 447: 435: 423: 388: 384: 365: 361: 349: 336: 293: 282: 271: 260: 218: 215: 147: 86: 185:Extended confirmed users 119:Extended confirmed users 681:Sender Policy Framework 658:URI blacklists such as 464:spamassassin.apache.org 85: 875:Links for german users 625: 555:standalone application 344: 759:and may only be used 737:, licensed under the 619: 356:The SpamAssassin team 343: 340:File:SpamAssassin.png 1782:Free e-mail software 767:Testing SpamAssassin 600:Anti-spam techniques 545:-based application ( 607:regular expressions 333: 996:Apache HTTP Server 739:Apache License 2.0 699:Bayesian filtering 693:Bayesian filtering 626: 547:Mail::SpamAssassin 541:SpamAssassin is a 498:generally regarded 480:Apache License 2.0 454:Apache License 2.0 345: 331: 163: 97: 1759: 1758: 870:SpamAssassin Wiki 469: 468: 442:Email spam filter 324: 149: 88: 68: 1789: 1747: 1746: 928: 921: 914: 905: 904: 846:Kerio MailServer 743:Artistic License 733:SpamAssassin is 622:Novell Evolution 537:Methods of usage 496:SpamAssassin is 476:computer program 425:Operating system 416: 411: 408: 406: 404: 402: 400: 341: 334: 330: 205: 204: 203: 201:→‎External links 191: 181: 162: 157: 139: 138: 137: 135:→‎External links 125: 115: 96: 69: 60: 59: 57: 52: 50: 42: 39: 21: 19: 1797: 1796: 1792: 1791: 1790: 1788: 1787: 1786: 1762: 1761: 1760: 1755: 1735: 1719: 1593: 1562: 1546: 1508: 943: 937: 932: 861: 785: 769: 731: 695: 647: 602: 588:can be made to 582:mail user agent 539: 523:SourceForge.net 507: 419: 397: 380: 321: 314: 305: 300: 291: 280: 269: 258: 251: 244: 235: 228: 211: 206: 199: 197: 195: 194: 193: 189: 187: 171: 169: 164: 158: 153: 145: 143:← Previous edit 140: 133: 131: 129: 128: 127: 123: 121: 105: 103: 98: 92: 84: 83: 82: 81: 79: 78: 77: 76: 75: 74: 65: 61: 55: 53: 48: 45: 43: 40: 38:Content deleted 37: 34: 29:← Previous edit 26: 25: 24: 17: 12: 11: 5: 1795: 1785: 1784: 1779: 1774: 1772:Spam filtering 1757: 1756: 1754: 1753: 1740: 1737: 1736: 1734: 1733: 1731:Apache License 1727: 1725: 1721: 1720: 1718: 1717: 1712: 1707: 1702: 1697: 1692: 1687: 1682: 1677: 1672: 1667: 1662: 1657: 1652: 1647: 1642: 1637: 1632: 1627: 1622: 1617: 1612: 1607: 1601: 1599: 1595: 1594: 1592: 1591: 1586: 1581: 1576: 1570: 1568: 1567:Other projects 1564: 1563: 1561: 1560: 1554: 1552: 1548: 1547: 1545: 1544: 1539: 1534: 1529: 1524: 1518: 1516: 1510: 1509: 1507: 1506: 1501: 1498: 1493: 1488: 1483: 1478: 1473: 1468: 1466:Traffic Server 1463: 1458: 1453: 1448: 1443: 1438: 1433: 1428: 1423: 1418: 1413: 1408: 1403: 1398: 1393: 1388: 1383: 1378: 1373: 1368: 1363: 1358: 1353: 1348: 1343: 1338: 1333: 1328: 1323: 1318: 1313: 1308: 1303: 1298: 1293: 1288: 1283: 1278: 1273: 1268: 1263: 1258: 1253: 1248: 1243: 1238: 1233: 1228: 1223: 1218: 1213: 1208: 1203: 1198: 1193: 1188: 1183: 1178: 1173: 1168: 1163: 1158: 1153: 1148: 1143: 1138: 1133: 1128: 1123: 1118: 1113: 1108: 1103: 1098: 1093: 1088: 1083: 1078: 1073: 1068: 1063: 1058: 1053: 1048: 1043: 1038: 1033: 1028: 1023: 1018: 1013: 1008: 1003: 998: 993: 988: 983: 978: 973: 968: 963: 958: 953: 947: 945: 939: 938: 931: 930: 923: 916: 908: 902: 901: 895: 889: 883: 877: 872: 867: 860: 859:External links 857: 856: 855: 849: 843: 840: 831: 819: 818: 813: 807: 801: 788:The following 784: 781: 768: 765: 730: 727: 719: 715: 708: 694: 691: 684: 683: 678: 673: 663: 656: 646: 643: 639:home directory 601: 598: 595: 572: 564: 548: 538: 535: 506: 503: 467: 466: 461: 457: 456: 451: 445: 444: 439: 433: 432: 430:Cross-platform 427: 421: 420: 418: 417: 394: 392: 386: 385: 382: 381: 372:3.1.8 / 371: 369: 367:Stable release 363: 362: 359: 358: 353: 347: 346: 328: 323: 322: 319: 317: 315: 312: 310: 307: 306: 303: 301: 298: 295: 294: 292: 289: 287: 284: 283: 281: 278: 276: 273: 272: 270: 267: 265: 262: 261: 259: 256: 253: 252: 249: 247: 245: 242: 240: 237: 236: 233: 231: 229: 226: 224: 221: 220: 217: 213: 212: 188: 183: 182: 167: 146: 122: 117: 116: 101: 70: 64: 62: 44: 36: 27: 23: 22: 14: 9: 6: 4: 3: 2: 1794: 1783: 1780: 1778: 1777:Perl software 1775: 1773: 1770: 1769: 1767: 1752: 1751: 1742: 1741: 1738: 1732: 1729: 1728: 1726: 1722: 1716: 1713: 1711: 1708: 1706: 1703: 1701: 1698: 1696: 1693: 1691: 1688: 1686: 1683: 1681: 1678: 1676: 1673: 1671: 1668: 1666: 1663: 1661: 1658: 1656: 1653: 1651: 1648: 1646: 1643: 1641: 1638: 1636: 1633: 1631: 1628: 1626: 1623: 1621: 1618: 1616: 1613: 1611: 1608: 1606: 1603: 1602: 1600: 1596: 1590: 1587: 1585: 1582: 1580: 1577: 1575: 1572: 1571: 1569: 1565: 1559: 1556: 1555: 1553: 1549: 1543: 1540: 1538: 1535: 1533: 1530: 1528: 1525: 1523: 1520: 1519: 1517: 1515: 1511: 1505: 1502: 1499: 1497: 1494: 1492: 1489: 1487: 1484: 1482: 1479: 1477: 1474: 1472: 1469: 1467: 1464: 1462: 1459: 1457: 1454: 1452: 1449: 1447: 1444: 1442: 1439: 1437: 1434: 1432: 1429: 1427: 1424: 1422: 1419: 1417: 1414: 1412: 1409: 1407: 1404: 1402: 1399: 1397: 1394: 1392: 1389: 1387: 1384: 1382: 1379: 1377: 1374: 1372: 1369: 1367: 1364: 1362: 1359: 1357: 1354: 1352: 1349: 1347: 1344: 1342: 1339: 1337: 1334: 1332: 1329: 1327: 1324: 1322: 1319: 1317: 1314: 1312: 1309: 1307: 1304: 1302: 1299: 1297: 1294: 1292: 1289: 1287: 1284: 1282: 1279: 1277: 1274: 1272: 1269: 1267: 1264: 1262: 1259: 1257: 1254: 1252: 1249: 1247: 1244: 1242: 1239: 1237: 1234: 1232: 1229: 1227: 1224: 1222: 1219: 1217: 1214: 1212: 1209: 1207: 1204: 1202: 1199: 1197: 1194: 1192: 1189: 1187: 1184: 1182: 1179: 1177: 1174: 1172: 1169: 1167: 1164: 1162: 1159: 1157: 1154: 1152: 1149: 1147: 1144: 1142: 1139: 1137: 1134: 1132: 1129: 1127: 1124: 1122: 1119: 1117: 1114: 1112: 1109: 1107: 1104: 1102: 1099: 1097: 1094: 1092: 1089: 1087: 1084: 1082: 1079: 1077: 1074: 1072: 1069: 1067: 1064: 1062: 1059: 1057: 1054: 1052: 1049: 1047: 1044: 1042: 1039: 1037: 1034: 1032: 1029: 1027: 1024: 1022: 1019: 1017: 1014: 1012: 1009: 1007: 1004: 1002: 999: 997: 994: 992: 989: 987: 984: 982: 979: 977: 974: 972: 969: 967: 964: 962: 959: 957: 954: 952: 949: 948: 946: 940: 936: 929: 924: 922: 917: 915: 910: 909: 906: 899: 896: 893: 890: 887: 884: 881: 878: 876: 873: 871: 868: 866: 863: 862: 853: 850: 847: 844: 841: 839: 835: 832: 829: 826: 825: 824: 823: 817: 814: 811: 808: 805: 802: 799: 796: 795: 794: 793: 791: 780: 778: 774: 764: 762: 758: 754: 750: 748: 744: 740: 736: 726: 724: 717: 713: 710: 706: 704: 700: 690: 687: 682: 679: 677: 674: 672: 671:Vipul's Razor 668: 664: 661: 657: 655: 652: 651: 650: 642: 640: 635: 632: 624:email client. 623: 618: 614: 610: 608: 597: 593: 591: 587: 583: 579: 574: 570: 568: 562: 560: 556: 552: 546: 544: 534: 532: 528: 524: 520: 516: 512: 502: 499: 494: 492: 488: 485: 481: 477: 473: 465: 462: 458: 455: 452: 450: 446: 443: 440: 438: 434: 431: 428: 426: 422: 415: 410: 407:/spamassassin 396: 395: 393: 391: 387: 383: 379: 375: 370: 368: 364: 360: 357: 354: 352: 348: 342: 335: 326: 318: 316: 311: 309: 308: 304: 302: 299: 297: 296: 288: 285: 277: 274: 266: 263: 257: 254: 248: 246: 241: 239: 238: 232: 230: 225: 223: 222: 214: 210: 202: 186: 179: 175: 170: 161: 156: 152: 144: 136: 120: 113: 109: 104: 95: 91: 73: 58: 51: 41:Content added 33: 30: 20: 1748: 1406:SpamAssassin 1405: 837: 821: 820: 787: 786: 770: 751: 732: 722: 711: 702: 696: 688: 685: 648: 636: 627: 611: 603: 575: 540: 514: 511:Justin Mason 508: 495: 472:SpamAssassin 471: 470: 351:Developer(s) 332:SpamAssassin 852:MailLaunder 804:MailScanner 790:open source 757:trademarked 735:open source 594:.procmailrc 578:mail filter 484:e-mail spam 374:February 14 209:Next edit → 32:Next edit → 1766:Categories 1635:Deltacloud 1421:Subversion 1311:OрenOffice 1196:Jackrabbit 1136:FreeMarker 1061:CloudStack 1046:CarbonData 1026:Bloodhound 838:SpamKiller 828:AntibodyMX 816:MIMEDefang 515:filter.plx 390:Repository 320:{{apache}} 313:{{apache}} 1630:Continuum 1551:Incubator 1504:ZooKeeper 1461:Trafodion 1451:TinkerPop 1151:Guacamole 1111:Empire-db 1096:Directory 1051:Cassandra 942:Top-level 880:sa-update 487:filtering 482:used for 1750:Category 1724:Licenses 1665:Marmotta 1496:XMLBeans 1476:Velocity 1436:Tapestry 1431:SystemDS 1426:Superset 1416:Struts 2 1411:Struts 1 1366:RocketMQ 1271:NetBeans 1251:mod_perl 1141:Geronimo 1031:Brooklyn 961:Airavata 956:ActiveMQ 951:Accumulo 944:projects 783:See also 745:and the 723:non-spam 718:sa-learn 714:sa-learn 707:sa-learn 676:Hashcash 586:procmail 557:or as a 527:April 20 219:Line 90: 216:Line 90: 178:contribs 112:contribs 56:Wikitext 1705:Tuscany 1700:Stanbol 1660:Jakarta 1655:Harmony 1615:Beehive 1558:Taverna 1542:Logging 1514:Commons 1331:Phoenix 1326:Parquet 1306:OpenNLP 1301:OpenJPA 1296:OpenEJB 1256:MyFaces 1181:Iceberg 1076:CouchDB 1071:Cordova 1056:Cayenne 1036:Calcite 966:Airflow 798:Citadel 505:History 460:Website 449:License 405:/viewvc 401:.apache 168:Vid2vid 102:Vid2vid 1645:Giraph 1620:iBATIS 1532:Daemon 1491:Xerces 1481:Wicket 1456:Tomcat 1441:Thrift 1361:Roller 1321:PDFBox 1261:Mynewt 1236:Mahout 1231:Lucene 1211:JMeter 1191:Impala 1186:Ignite 1161:Hadoop 1146:Groovy 1081:cTAKES 1066:Cocoon 976:Ambari 971:Allura 834:McAfee 596:file. 567:daemon 559:client 67:Inline 49:Visual 1695:Sqoop 1690:Slide 1685:Shale 1680:River 1670:MXNet 1625:Click 1610:AxKit 1598:Attic 1589:Log4j 1574:Batik 1537:Jelly 1500:Yetus 1486:Xalan 1401:Storm 1396:Spark 1386:Sling 1381:SINGA 1376:Shiro 1371:Samza 1351:Pivot 1346:Pinot 1291:Oozie 1286:OFBiz 1281:NuttX 1276:Nutch 1241:Maven 1226:Kylin 1216:Kafka 1201:James 1171:Helix 1166:HBase 1131:Flume 1126:Flink 1116:Felix 1106:Druid 1101:Drill 1091:Derby 1041:Camel 1016:Axis2 991:Arrow 986:Aries 810:KMail 777:EICAR 773:GTUBE 660:SURBL 571:spamd 563:spamc 474:is a 192:edits 190:1,032 126:edits 124:1,032 1710:Wave 1650:Hama 1640:Etch 1605:Apex 1522:BCEL 1471:UIMA 1446:Tika 1391:Solr 1356:Qpid 1266:NiFi 1246:MINA 1221:Kudu 1206:Jena 1176:Hive 1156:Gump 1121:Flex 1021:Beam 1011:Axis 1006:Avro 669:and 631:MIME 590:pipe 551:CPAN 543:Perl 531:2001 519:1997 437:Type 403:.org 378:2007 174:talk 160:undo 155:edit 108:talk 94:edit 1715:XML 1675:ODE 1584:Ivy 1579:FOP 1527:BSF 1341:Pig 1336:POI 1316:ORC 1086:CXF 1001:APR 981:Ant 703:and 549:in 525:on 491:DNS 399:svn 1768:: 763:. 749:. 533:. 529:, 376:, 279:* 268:* 176:| 110:| 927:e 920:t 913:v 569:( 561:( 409:/ 180:) 172:( 114:) 106:(

Index

Browse history interactively
← Previous edit
Next edit →
Visual
Wikitext

Revision as of 22:59, 22 March 2007
edit
Vid2vid
talk
contribs
Extended confirmed users
→‎External links
← Previous edit
Revision as of 23:00, 22 March 2007
edit
undo
Vid2vid
talk
contribs
Extended confirmed users
→‎External links
Next edit →
File:SpamAssassin.png
Developer(s)
The SpamAssassin team
Stable release
February 14
2007
Repository

Text is available under the Creative Commons Attribution-ShareAlike License. Additional terms may apply.