[
https://issues.apache.org/jira/browse/TS-3938?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15159901#comment-15159901
]
Bryan Call commented on TS-3938:
--------------------------------
With hardening:
{code}
[bcall@homer trafficserver]$ size --format=sysv /usr/local/bin/traffic_server
/usr/local/bin/traffic_server :
section size addr
.interp 28 624
.note.ABI-tag 32 652
.note.gnu.build-id 36 684
.gnu.hash 55684 720
.dynsym 203712 56408
.dynstr 280445 260120
.gnu.version 16976 540566
.gnu.version_r 512 557544
.rela.dyn 166512 558056
.rela.plt 16968 724568
.init 26 741536
.plt 11328 741568
.text 3547250 752896
.fini 9 4300148
.rodata 371361 4300160
.eh_frame_hdr 52572 4671524
.eh_frame 297388 4724096
.gcc_except_table 37171 5021484
.tbss 32 7158176
.init_array 1128 7158176
.fini_array 8 7159304
.jcr 8 7159312
.data.rel.ro 96160 7159328
.dynamic 784 7255488
.got 5928 7256272
.data 17344 7262208
.bss 6154080 7279552
.comment 57 0
.debug_aranges 127232 0
.debug_info 24761745 0
.debug_abbrev 905936 0
.debug_line 2396123 0
.debug_frame 96 0
.debug_str 1098848 0
.debug_loc 16834550 0
.debug_ranges 6277424 0
Total 63735493
{code}
> Add hardening (fortify) as an option to configure
> -------------------------------------------------
>
> Key: TS-3938
> URL: https://issues.apache.org/jira/browse/TS-3938
> Project: Traffic Server
> Issue Type: New Feature
> Components: Build
> Reporter: Leif Hedstrom
> Assignee: Bryan Call
> Fix For: sometime
>
>
> It might be useful to add an option, e.g. --with-hardening, such that we can
> build with various hardening compiler options. For example. I've used
> {code}
> CC="/opt/gcc5/bin/gcc"; export CC
> CXX="/opt/gcc5/bin/g++"; export CXX
> CFLAGS="-fstack-protector -fno-omit-frame-pointer"; export CFLAGS
> CXXFLAGS="-fstack-protector -fno-omit-frame-pointer"; export CXXFLAGS
> CPPFLAGS="-D_FORTIFY_SOURCE=2"; export CPPFLAGS
> LDFLAGS="-Wl,-z,relro -Wl,-z,now"; export LDFLAGS
> "./configure" \
> "--enable-experimental-plugins" \
> "--prefix=/opt/ats" \
> "CC=/opt/gcc5/bin/gcc" \
> "CXX=/opt/gcc5/bin/g++" \
> "CFLAGS=-fstack-protector -fno-omit-frame-pointer" \
> "CXXFLAGS=-fstack-protector -fno-omit-frame-pointer" \
> "CPPFLAGS=-D_FORTIFY_SOURCE=2" \
> "LDFLAGS=-Wl,-z,relro -Wl,-z,now" \
> "$@"
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)