F5 Sites
  • F5.com
  • LearnF5
  • NGINX
  • MyF5
  • Partner Central
Contact
  • Under Attack?
  • F5 Support
  • DevCentral Support
  • F5 Sales
  • NGINX Sales
  • F5 Professional Services
Skip to contentBrand Logo
Forums
CrowdSRC
Articles
Groups
EventsSuggestionsHow Do I...?
RegisterSign In
  1. DevCentral
  2. CrowdSRC
  3. CodeShare

FTPS_SSL_ Termination

Problem this snippet solves: This iRule is meant to act as a full FTPS termination rule that behaves similarly to HTTPS termination. It forces either an implicit (port 990 by default) or explicit (p...
Published Mar 17, 2015
Version 1.0
application delivery
devops
iRules
security
bob_ziuchkovsk1's avatar
bob_ziuchkovsk1
Icon for Nimbostratus rankNimbostratus
Joined October 12, 2010
View Profile
bob_ziuchkovsk1's avatar
bob_ziuchkovsk1
Icon for Nimbostratus rankNimbostratus
Joined October 12, 2010
View Profile
steffen's avatar
steffen
Icon for Nimbostratus rankNimbostratus
Oct 13, 2022

Hey @bob_ziuchkovsk1
thanks for your FTPS iRule

There are still a few small things that need to be adjusted to make it work.

1. The same variable again "static::pasv_max_port" is incorrect it is already in use.
2. To use this iRule on multiple virtual servers it needs a little more dynamic.

 

 # -- REMOVE OLD --

 # Vserver IP to advertise for incoming PASV data channel connections
 # NOTE: the commas are NOT a typo.  This is the format used by FTP protocol
 set static::pasv_max_port "10,0,0,46"


 # -- ADD (under "when CLIENTSSL_DATA" ) --

 # uses the known virtual server ip address (client context)
 set static::vserverip [IP::local_addr]
 set static::vserverip_comma [string map {. ,} $static::vserverip]



 # -- CHANGE ( under "when SERVER_DATA" ) --

 # respoding the virtual server ip address
 set pasv_response "227 Entering Passive Mode ($static::vserverip_comma,$our_pasv_str)\r\n"

 

Tested this on Version: 16.1

 

ABOUT DEVCENTRAL

DevCentral NewsTechnical ForumTechnical ArticlesTechnical CrowdSRCCommunity GuidelinesDevCentral EULAGet a Developer Lab LicenseBecome a DevCentral MVP

RESOURCES

Product DocumentationWhite PapersGlossaryCustomer StoriesWebinarsFree Online CoursesF5 CertificationLearnF5 Training

SUPPORT

Manage SubscriptionsProfessional ServicesProfessional ServicesCreate a Service RequestSoftware DownloadsSupport Portal

PARTNERS

Find a Reseller PartnerTechnology AlliancesBecome an F5 PartnerLogin to Partner Central

F5 logo©2024 F5, Inc. All rights reserved.
TrademarksPoliciesPrivacyCalifornia PrivacyDo Not Sell My Personal Information