Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    ssh version causing PCI scan failures

    Scheduled Pinned Locked Moved General pfSense Questions
    31 Posts 6 Posters 3.0k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • johnpozJ
      johnpoz LAYER 8 Global Moderator @JVComputers
      last edited by johnpoz

      Ok - that is fine.. But there is NOTHING in the pci docs that say you have to lower your security stance to allow for such a scan.. Opening up ssh, when it is NOT open is not part of pci compliance..

      Be like saying hey here eat this shrimp we are testing if you are allergic - but I don't eat shrimp! When I ate it I got sick.. So yeah if I eat it again I will get sick, so I don't eat it!! So why should I open up ssh to the internet for you to scan.. When I do not allow ssh -- scan me!! Do you see ssh open.. NO!! ;)

      Your rules only allow specific IPs to use your port forwards.. Then add their IPs to those rules - that is all that is required to do..

      Where you could get in trouble.. Is if you had ssh open, but you specifically blocked their IPs.. Show them your rules that only allow the trusted IPs, and that their scanning IPs have been added to the rules. And there are no other rules allowing stuff from other trusted IPs or that they have been blocked from, etc.

      An intelligent man is sometimes forced to be drunk to spend time with his fools
      If you get confused: Listen to the Music Play
      Please don't Chat/PM me for help, unless mod related
      SG-4860 24.11 | Lab VMs 2.7.2, 24.11

      J 1 Reply Last reply Reply Quote 0
      • J
        JVComputers @johnpoz
        last edited by

        @johnpoz They never specified specific ports to forward, so I just have rules set up to allow their processing IPs full access to the LAN IP that does the card processing - not port forwards, just an allow rule. It sounds like that is the problem?

        johnpozJ 1 Reply Last reply Reply Quote 0
        • johnpozJ
          johnpoz LAYER 8 Global Moderator @JVComputers
          last edited by johnpoz

          @jvcomputers said in ssh version causing PCI scan failures:

          so I just have rules set up to allow their processing IPs full access to the LAN IP

          Well then yeah they could hit you on some service that is not part of pci when they scan those IPs.. Ie if you have ssh open on one of these IPs they are scanning.. But again this would not be pfsense ssh service. But if you a rule open to IP X, that allows everything then sure anything on X is fair game to have to be secure.

          Your rules should be set to only allow the ports required to do whatever it is your doing.. This is security 101.. If I am running a FTP server on IP 1.2.3.4, I sure do not also allow ssh, and httpd and snmp, and telnet and whatever else.. But if that is what you have is an any any rule to 1.2.3.4 then sure anything open on 1.2.3.4 is open to scrutiny.

          If you have a rule that allows access to IP 1.2.3.4 and ssh is on 1.2.3.4, then yes ssh needs to meet their security requirements.. But that would not be pfsense ssh.

          pci requires that they scan all your public facing IPs.. So yeah if you had ssh open on 1.2.3.5 while your pci stuff using 1.2.3.4 that would be a problem. But if you don't have anything open on 1.2.3.5 then its not a problem - they scanned it and no services are open..

          This very common setup.. Where company owns public space, and .X is used for outbound traffic only, and .Y is used for inbound.. While they will scan both .x and .y - its fine if nothing shows as open on .x..

          An intelligent man is sometimes forced to be drunk to spend time with his fools
          If you get confused: Listen to the Music Play
          Please don't Chat/PM me for help, unless mod related
          SG-4860 24.11 | Lab VMs 2.7.2, 24.11

          J 1 Reply Last reply Reply Quote 0
          • J
            JVComputers @johnpoz
            last edited by

            @johnpoz They're just Windows 10 boxes, they don't have 22 open. I don't think Windows even has SSH server installed unless it's done so intentionally and it's not on either of these machines. Here's a shot of the rules I have in place.

            f26b4080-8b4c-48ee-952e-1334f9918837-image.png

            The "CardPointe_DataCenter" alias is the one used for regular processing and consists of two domains: fts.cardconnect.com, cardpointe.com

            CardPoint_Trustwave_24 is their block of IPs used for some of the scanning (64.37.231.0/24)

            And the CardPoint_Trustwave_Others is a bunch of other IPs they use for scanning

            cce28491-99a0-4f35-a97c-8a1614c16ab1-image.png

            johnpozJ 1 Reply Last reply Reply Quote 0
            • johnpozJ
              johnpoz LAYER 8 Global Moderator @JVComputers
              last edited by johnpoz

              The rules that allow "this firewall" are BAD!!! Why would you ever put those in..

              What rules did you have when your CC stuff works? The DC one? That is allowed to Mel_office.. This is the rule you want to add their scanning IPs to.. the DC alias..

              And also the campworks external.. There should NEVER be a need to create specific rules to allow for pci scanning.. Only possible edit of existing rules to allow them to scan what you have open.

              I take it your lan net is public space then, since otherwise that rule really would never work..

              edit: BTW windows can easy run ssh these days.. Its as simple as clicking install on a feature.. So it would be possible for windows to be running ssh server very easy.

              https://docs.microsoft.com/en-us/windows-server/administration/openssh/openssh_install_firstuse

              An intelligent man is sometimes forced to be drunk to spend time with his fools
              If you get confused: Listen to the Music Play
              Please don't Chat/PM me for help, unless mod related
              SG-4860 24.11 | Lab VMs 2.7.2, 24.11

              J 1 Reply Last reply Reply Quote 0
              • J
                JVComputers @johnpoz
                last edited by

                @johnpoz Okay, so, again, I've tried adding the scanning IPs to the same rule with the Data Center and they fail me because they can't see the firewall. That's why I put in the "this firewall" ruleset - It seems to be the only way they will not fail the scan completely. Anything less than that and they fail the scan stating they don't have access to the public IP and can't scan anything. I thought they had to be able to have unfettered access to "this firewall" in order to be able to check all the firewall rules and find out what ports are open and where they're going.

                We've got VLANs set up for a few different Wi-Fi networks, but now that you've got me thinking more about this, I do still have all the switches and access points on the main LAN (VLAN1) and they've all got SSH capability, so it could be any one of them causing the error. I'll have to move them all to a management VLAN. Something I was planning to do anyway, but never got around to.

                I'm going to start logging everything to do with the Data Center rule and find out exactly what ports are being used so I can set up a port forward rule for only those ports to the Mel_Office alias and try adding those scanning IPs to the same port forward and hope that works.

                Regarding Windows and SSH - yeah, I know it can run it, but not by default and the machine in question doesn't have port 22 open, either.

                Thanks for your help with all this. I think I'm on the right track now.

                johnpozJ 1 Reply Last reply Reply Quote 0
                • johnpozJ
                  johnpoz LAYER 8 Global Moderator @JVComputers
                  last edited by johnpoz

                  @jvcomputers said in ssh version causing PCI scan failures:

                  they can't see the firewall.

                  Then they are freaking IDIOTS! There is NOTHING!!! I MEAN NOTHING in the PCI requirements that they need too see anything of the sort - PERIOD!!

                  These are the rules you have on your firewall.. That is ALL they should ever see! What you have open for PCI to function.

                  Have them show you in the pci requirements where you are suppose to open up traffic.. That is NOT already open..

                  Its in requirements 11 (scanning) of the standard if they need help finding where to look - have them point out in that standard where is says to expose something that is not normally exposed.

                  edit:
                  Step 1 is firewall controls.. And states "and should restrict all untrusted traffic except in cases where that communication protocol is required to process cardholder data."

                  How is scanning every port, that is NOT allowed do that? How is ssh to your firewall, that is not allowed via your firewall controls part of protocol that processes card holder data? Please ask them to explain that to you - in details and in writing specifically state where in the compliance regulations it says to modify your firewall rules to open a port that is not used for card holder data.. And per your company policy is not open to the the internet in the first place.

                  The most they can do is require a scan after firewall changes - to validate you do not have stuff open to the internet or have opened up anything else in your pci rules that would be an issue.

                  Your firewall not having ssh open is good thing! And directly is involved in step 1 of compliance where you create firewall rules to restrict traffic only the protocols required for pci.

                  To be honest - per the requirements. You could prob get away with sorry our firewall policies only allow access to pci from these IPs.. But in the spirit of checking the devices that actually are involved in the pci stuff. I will add your ips to the rules that are used for access to pci stuff.

                  I have gone through hundreds of security audits... If your firewall controls do not allow access to X, then that is the policy.. You do not change your policy to look for something that is not accessible. Part of the scanning is also a pen test.. When they will check if they can bypass your controls that restrict access.. But no you are not required, and should not be opening up your controls for them to scan.. Other than what is directly used for pci..

                  The point of scanning your external IPs is looking for stuff that should be restrictive - if it can not be restricted.. Then it needs to meet specific requirements for security.. Like version 2 of service vs 1, or turn 2fa or restrict to these ciphers or algorithms, etc.. No where in any firewall scan or security test for compliance should you be opening up services that are not used by your company in normal operation. If you had ssh open to the internet as part of your company services than yes it could be in question. So you would either need to stop access to it, or make sure it met security settings for use.

                  An intelligent man is sometimes forced to be drunk to spend time with his fools
                  If you get confused: Listen to the Music Play
                  Please don't Chat/PM me for help, unless mod related
                  SG-4860 24.11 | Lab VMs 2.7.2, 24.11

                  J 1 Reply Last reply Reply Quote 0
                  • J
                    JVComputers @johnpoz
                    last edited by JVComputers

                    @johnpoz I'll have to continue fighting with them, then. We changed firewalls because the first time we went through this issue where they stated "Verify your Scan Setup for correct IP Address and Domain Name information. Configure your network to allow access from Trustwave scanners." We made sure nothing was open that shouldn't be and disputed the failure, stating that our network is "hidden" (which is also part of their acceptance so long as you tell them that's the case) and they let us pass. But, when we tried that again on the next scan, they wouldn't allow it and started charging us $150 a month for failure. I didn't think we should have to dispute this every quarter, anyway, and deal with getting charged and having to deal with refunds and the bookkeeping that goes along with all that. So, I convinced the client to switch to pfSense and the first scan went through fine. Then they started trying to charge a $50 a month compliance fee for something else, so I started looking into it and here I am.

                    If I ever figure this out, I'll post here to help others decipher this maze of insanity.

                    GertjanG johnpozJ 2 Replies Last reply Reply Quote 0
                    • GertjanG
                      Gertjan @JVComputers
                      last edited by

                      @jvcomputers

                      Just for my own curiosity, you have to do what with credit cards to merit such a scan ?

                      I'm not a bank, just a hotel, and we deal with credit cards for .... they day they showed up, something like 1988 here in France.
                      These days, credit card equipment is just jacked into a local switch with 'Internet' access. Done. No other questions asked.

                      No "help me" PM's please. Use the forum, the community will thank you.
                      Edit : and where are the logs ??

                      johnpozJ 1 Reply Last reply Reply Quote 0
                      • johnpozJ
                        johnpoz LAYER 8 Global Moderator @Gertjan
                        last edited by johnpoz

                        Your not the one processing the CC @Gertjan your just an end user.. You don't store card holder data, etc. If the pci data never touches your companies network, then you do need to meet the requirements.

                        Sounds like a scam to me to be honest. There is NOTHING in the requirement that you need to open services to be scanned that are not part of pci, and not open to the internet in general.

                        As stated before - filtering traffic to ssh on purpose block them, while its open to others could be seen as failure. But show them the rules - you do not allow traffic to ssh to anyone, you do not allow access to any firewall services to anyone, etc..

                        If they are saying they are not seeing the firewall - which is how it should be setup! Allow ping.. There you go - you see the firewall, that is the only service we allow that can talk to the firewall at all.

                        Another part of the compliance is segmentation, you are on purpose suppose to segment the pci devices so that they can not see anything they do not need to see. While you might need to show that only specific users have admin access to the firewall and that they are using their own unique IDs, and you limit where they can access the firewall from, and that access is logged, etc. Opening up ssh to the scan is not part of the requirement.. Since it can only be accessed via a secure location (your network management vlan) and from specific individuals, with unique login controls and logging of said access.

                        An intelligent man is sometimes forced to be drunk to spend time with his fools
                        If you get confused: Listen to the Music Play
                        Please don't Chat/PM me for help, unless mod related
                        SG-4860 24.11 | Lab VMs 2.7.2, 24.11

                        1 Reply Last reply Reply Quote 0
                        • johnpozJ
                          johnpoz LAYER 8 Global Moderator @JVComputers
                          last edited by

                          @jvcomputers

                          You might want to take a look at this thread - same subject as yours, just with web gui vs ssh. I linked to the ASV document guide.. Ie guidelines that ASVs are suppose to use when scanning.

                          https://forum.netgate.com/topic/163844/pci-dss-compliance-vulnerabilities-found-webgui

                          Clearly stated in that doc..
                          "Temporary configuration changes do not require that the scan customer “white list” or provide the ASV a higher level of network access."

                          An intelligent man is sometimes forced to be drunk to spend time with his fools
                          If you get confused: Listen to the Music Play
                          Please don't Chat/PM me for help, unless mod related
                          SG-4860 24.11 | Lab VMs 2.7.2, 24.11

                          1 Reply Last reply Reply Quote 1
                          • First post
                            Last post
                          Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.