1 | # -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4 |
---|
2 | # $Id: Portfile 151889 2016-08-23 21:31:57Z mojca@macports.org $ |
---|
3 | |
---|
4 | PortSystem 1.0 |
---|
5 | PortGroup perl5 1.0 |
---|
6 | |
---|
7 | name metasploit2 |
---|
8 | conflicts metasploit3 |
---|
9 | version 2.7 |
---|
10 | revision 3 |
---|
11 | categories security |
---|
12 | license {Artistic-1 GPL-2} GPL-2+ APSL-1.1 Noncommercial Restrictive |
---|
13 | maintainers nomaintainer |
---|
14 | homepage http://metasploit.com/ |
---|
15 | platforms darwin |
---|
16 | |
---|
17 | description Tools and information for security research and pentesting |
---|
18 | long_description The Metasploit Project goal is to provide useful information to people \ |
---|
19 | who perform penetration testing, IDS signature development, and exploit \ |
---|
20 | research. This framework was created to fill the gaps in the information \ |
---|
21 | publicly available on various exploitation techniques and to create a \ |
---|
22 | useful resource for exploit developers. The tools and information are \ |
---|
23 | provided for legal security research and testing purposes only. |
---|
24 | |
---|
25 | # This no longer works. New versions are probably available under |
---|
26 | # https://github.com/rapid7/metasploit-framework |
---|
27 | # Maybe it's time to retire version 2 of this port anyway |
---|
28 | #master_sites http://www.metasploit.com/tools/ |
---|
29 | master_sites macports_distfiles |
---|
30 | |
---|
31 | distname framework-${version} |
---|
32 | |
---|
33 | checksums rmd160 cfdf2705522c845bb4405413207a7df0f3873b94 \ |
---|
34 | sha256 516952772aaa8982628460b927c9119850925f870903c5a131a9c9f0390cf77f |
---|
35 | |
---|
36 | perl5.branches 5.24 |
---|
37 | |
---|
38 | depends_run port:perl${perl5.major} \ |
---|
39 | port:p${perl5.major}-net-ssleay \ |
---|
40 | port:p${perl5.major}-term-readline-gnu |
---|
41 | |
---|
42 | use_configure no |
---|
43 | |
---|
44 | build { |
---|
45 | ## remove the .svn/ directories, no need to move them around |
---|
46 | system "cd ${worksrcpath} && find . -type d -name '\.svn' | xargs /bin/rm -rf" |
---|
47 | foreach file [glob -directory ${worksrcpath} msf*] { |
---|
48 | reinplace "s|#!/usr/bin/perl|#!${perl5.bin}|" $file |
---|
49 | } |
---|
50 | } |
---|
51 | |
---|
52 | destroot { |
---|
53 | set metasploitTargetDir "libexec/${name}" |
---|
54 | xinstall -d -m 755 ${destroot}${prefix}/${metasploitTargetDir} |
---|
55 | foreach file [glob -directory ${workpath}/${worksrcdir} *] { |
---|
56 | file copy ${file} ${destroot}${prefix}/${metasploitTargetDir} |
---|
57 | } |
---|
58 | foreach file [glob -directory ${destroot}${prefix}/${metasploitTargetDir} msf*] { |
---|
59 | set useFile [file tail ${file}] |
---|
60 | ## 'file link' doesn't play nice, it doesn't (seem) to want to do relative paths... |
---|
61 | ## file link -symbolic ${useFile} ../${metasploitTargetDir}/${useFile} |
---|
62 | ## so use 'system "ln -s ..."' instead. |
---|
63 | system "cd ${destroot}${prefix}/sbin && /bin/ln -s ../${metasploitTargetDir}/${useFile} ${useFile}" |
---|
64 | } |
---|
65 | } |
---|