|
| 1 | +--- a/theme/spintech-child/functions.php |
| 2 | ++++ b/theme/spintech-child/functions.php |
| 3 | +@@ -509,6 +509,16 @@ |
| 4 | + exit; |
| 5 | + } |
| 6 | + |
| 7 | ++ // Canonical scope is signed and persisted before asynchronous work. |
| 8 | ++ if ( function_exists( 'ct_scan_normalize_target' ) ) { |
| 9 | ++ $target = ct_scan_normalize_target( wp_unslash( $_POST['ct_website'] ?? '' ) ); |
| 10 | ++ if ( is_wp_error( $target ) ) { |
| 11 | ++ wp_safe_redirect( $fail ); |
| 12 | ++ exit; |
| 13 | ++ } |
| 14 | ++ $website = $target; |
| 15 | ++ } |
| 16 | ++ |
| 17 | + $body = "Promotion: {$promo['id']}\n" |
| 18 | + . "Referred by: {$referred_by}\n" |
| 19 | + . "Name: {$name}\n" |
| 20 | +@@ -528,6 +538,21 @@ |
| 21 | + } |
| 22 | + update_post_meta( $request_id, '_ct_ref', $referred_by ); |
| 23 | + |
| 24 | ++ if ( function_exists( 'ct_scan_on_request_ready' ) ) { |
| 25 | ++ $fields = array( 'target' => $website, 'email' => $email, 'name' => $name, 'referrer' => $referred_by ); |
| 26 | ++ $saved = true; |
| 27 | ++ foreach ( array( 'target', 'email', 'name' ) as $field ) { |
| 28 | ++ $key = '_ct_scan_' . $field; |
| 29 | ++ update_post_meta( $request_id, $key, wp_slash( $fields[ $field ] ) ); |
| 30 | ++ $saved = $saved && get_post_meta( $request_id, $key, true ) === $fields[ $field ]; |
| 31 | ++ } |
| 32 | ++ if ( $saved && get_post_meta( $request_id, '_ct_ref', true ) === $referred_by ) { |
| 33 | ++ do_action( 'ct_promo_request_ready', $request_id, $fields ); |
| 34 | ++ } else { |
| 35 | ++ update_post_meta( $request_id, '_ct_scan_enqueue_error', 'request_metadata_not_saved' ); |
| 36 | ++ } |
| 37 | ++ } |
| 38 | ++ |
| 39 | + ct_promo_send_notification( |
| 40 | + $request_id, |
| 41 | + get_option( 'admin_email' ), |
| 42 | +--- a/mu-plugins/ct-promo-terms.php |
| 43 | ++++ b/mu-plugins/ct-promo-terms.php |
| 44 | +@@ -2,7 +2,7 @@ |
| 45 | + /** |
| 46 | + * Plugin Name: CompleteTech Promo Terms |
| 47 | + * Description: Requires acceptance of the PHP2Shell scan terms on the promo form, records the acceptance, and attaches a filled-in copy of the terms to each request and its notification email. |
| 48 | +- * Version: 1.0.0 |
| 49 | ++ * Version: 1.1.0 |
| 50 | + */ |
| 51 | + |
| 52 | + defined( 'ABSPATH' ) || exit; |
| 53 | +@@ -11,7 +11,7 @@ |
| 54 | + function ct_promo_terms() { |
| 55 | + return array( |
| 56 | + 'page_id' => 658, |
| 57 | +- 'version' => '2026-10-21', |
| 58 | ++ 'version' => '2026-10-21-r2', |
| 59 | + 'title' => 'Free PHP2Shell Scan: Authorization and Promotion Terms', |
| 60 | + 'path' => '/services/website-security/php2shell-scan-terms/', |
| 61 | + ); |
| 62 | +@@ -119,11 +119,19 @@ |
| 63 | + return; |
| 64 | + } |
| 65 | + foreach ( array( 'version', 'url', 'sha256', 'accepted_at', 'ip', 'remote_addr', 'user_agent' ) as $key ) { |
| 66 | +- update_post_meta( $post_id, '_ct_terms_' . $key, $acceptance[ $key ] ); |
| 67 | ++ update_post_meta( $post_id, '_ct_terms_' . $key, wp_slash( $acceptance[ $key ] ) ); |
| 68 | + } |
| 69 | + $contract = ct_promo_terms_contract( $post_id, $post->post_content, $acceptance ); |
| 70 | + $GLOBALS['ct_promo_acceptance']['contract'] = $contract; |
| 71 | + update_post_meta( $post_id, '_ct_terms_contract', wp_slash( $contract ) ); |
| 72 | ++ // Queue eligibility requires a complete, durably saved acceptance record. |
| 73 | ++ $terms_saved = get_post_meta( $post_id, '_ct_terms_contract', true ) === $contract; |
| 74 | ++ foreach ( array( 'version', 'url', 'sha256', 'accepted_at', 'ip', 'remote_addr', 'user_agent' ) as $key ) { |
| 75 | ++ $terms_saved = $terms_saved && get_post_meta( $post_id, '_ct_terms_' . $key, true ) === $acceptance[ $key ]; |
| 76 | ++ } |
| 77 | ++ if ( $terms_saved ) { |
| 78 | ++ update_post_meta( $post_id, '_ct_terms_saved', '1' ); |
| 79 | ++ } |
| 80 | + wp_update_post( wp_slash( array( |
| 81 | + 'ID' => $post_id, |
| 82 | + 'post_content' => $post->post_content . "\n\n" . $contract, |
| 83 | +--- a/theme/spintech-child/templates/template-service-brief.php |
| 84 | ++++ b/theme/spintech-child/templates/template-service-brief.php |
| 85 | +@@ -161,10 +161,10 @@ |
| 86 | + <span class="eyebrow service-brief-offer-head">Limited offer · through Nov 20, 2026</span> |
| 87 | + <h2>Request your free PHP2Shell scan</h2> |
| 88 | + <?php if ( 'sent' === $promo_state ) : ?> |
| 89 | +- <p class="service-brief-form-note" role="status">Thanks — your request is in. We’ll be in touch within one business day.</p> |
| 90 | ++ <p class="service-brief-form-note" role="status">Thanks — your request is saved. Watch for a separate email to confirm authorization before scanning starts. We’ll be in touch within one business day.</p> |
| 91 | + <?php else : ?> |
| 92 | + <?php if ( 'error' === $promo_state ) : ?> |
| 93 | +- <p class="service-brief-form-note is-error" role="alert">Please fill in your name, a valid email, and your website, then try again.</p> |
| 94 | ++ <p class="service-brief-form-note is-error" role="alert">Please enter your name, a valid email, and your website homepage (for example, https://example.com/), then try again.</p> |
| 95 | + <?php elseif ( 'terms' === $promo_state ) : ?> |
| 96 | + <p class="service-brief-form-note is-error" role="alert">Please read and agree to the scan terms, then try again.</p> |
| 97 | + <?php endif; ?> |
| 98 | +@@ -174,7 +174,7 @@ |
| 99 | + <?php wp_nonce_field( 'ct_promo_request', 'ct_promo_nonce' ); ?> |
| 100 | + <label>Name <input type="text" name="ct_name" autocomplete="name" required></label> |
| 101 | + <label>Email <input type="email" name="ct_email" autocomplete="email" required></label> |
| 102 | +- <label>Website <input type="url" name="ct_website" placeholder="https://" autocomplete="url" required></label> |
| 103 | ++ <label>Website <input type="url" name="ct_website" placeholder="https://example.com/" autocomplete="url" required></label> |
| 104 | + <label>Phone (optional) <input type="tel" name="ct_phone" autocomplete="tel"></label> |
| 105 | + <label class="service-brief-form-hp" aria-hidden="true">Leave blank <input type="text" name="ct_hp" tabindex="-1" autocomplete="off"></label> |
| 106 | + <?php if ( function_exists( 'ct_promo_terms' ) ) : $ct_terms = ct_promo_terms(); ?> |
| 107 | +--- a/content/php2shell-scan-terms.html |
| 108 | ++++ b/content/php2shell-scan-terms.html |
| 109 | +@@ -1,5 +1,5 @@ |
| 110 | + <!-- wp:paragraph --> |
| 111 | +-<p><strong>Version 2026-10-21</strong> · Effective October 21, 2026 · Offer ends November 20, 2026</p> |
| 112 | ++<p><strong>Version 2026-10-21-r2</strong> · Effective October 21, 2026 · Offer ends November 20, 2026</p> |
| 113 | + <!-- /wp:paragraph --> |
| 114 | + |
| 115 | + <!-- wp:paragraph --> |
| 116 | +@@ -12,6 +12,10 @@ |
| 117 | + |
| 118 | + <!-- wp:paragraph --> |
| 119 | + <p>You confirm that you own the website you entered (the "Website") or are authorized by its owner to request security testing of it, and that you are at least 18 years old. Do not submit the form for a website you do not control, and do not let anyone else submit it for you. If your website is hosted by a third party, you are responsible for any notice or permission your hosting contract requires before external testing. If any of these confirmations is untrue, you agree to cover the reasonable costs and claims that result.</p> |
| 120 | ++<!-- /wp:paragraph --> |
| 121 | ++ |
| 122 | ++<!-- wp:paragraph --> |
| 123 | ++<p>Before testing starts, we send a confirmation link to the email address you entered. Open the link and press the confirmation button to confirm your authority and the website scope. Merely opening the email or link does not start a scan. Callers may send you the request link, but must not sign or confirm on your behalf. Confirmation establishes control of the email address; it does not independently prove website ownership. The signed scope is the website hostname shown on the confirmation page. Other hostnames, including a www variant, require separate authorization.</p> |
| 124 | + <!-- /wp:paragraph --> |
| 125 | + |
| 126 | + <!-- wp:heading {"level":3} --> |
| 127 | +@@ -38,6 +42,10 @@ |
| 128 | + |
| 129 | + <!-- wp:paragraph --> |
| 130 | + <p>Checks run at a low request rate from identified Complete Tech systems and are designed not to affect your site's availability.</p> |
| 131 | ++<!-- /wp:paragraph --> |
| 132 | ++ |
| 133 | ++<!-- wp:paragraph --> |
| 134 | ++<p>After confirmation, the automated PHP2Shell portion checks the PHP version advertised in public response headers. A potentially affected version is not proof of exploitability, and an advertised fixed version is not proof that the website is safe. Hidden, conflicting or vendor-modified versions may be inconclusive. The other checks listed above remain part of our separate review before the full report is complete.</p> |
| 135 | + <!-- /wp:paragraph --> |
| 136 | + |
| 137 | + <!-- wp:heading {"level":3} --> |
0 commit comments