diff --git a/app/controllers/activitypub/inboxes_controller.rb b/app/controllers/activitypub/inboxes_controller.rb
index 7d0bc74d3ee3bbfb6efdf3fee0c779c75fd937e3..af51e32d5d31148512b655a9a225340babe40e6a 100644
--- a/app/controllers/activitypub/inboxes_controller.rb
+++ b/app/controllers/activitypub/inboxes_controller.rb
@@ -11,7 +11,7 @@ class ActivityPub::InboxesController < Api::BaseController
       process_payload
       head 202
     else
-      [signature_verification_failure_reason, 401]
+      render plain: signature_verification_failure_reason, status: 401
     end
   end
 
diff --git a/app/controllers/api/salmon_controller.rb b/app/controllers/api/salmon_controller.rb
index 143e9d3cdc6b8b30e072ea352613f4f3ecdfa205..ac5f3268d8c78a28428369c0166f430d71515958 100644
--- a/app/controllers/api/salmon_controller.rb
+++ b/app/controllers/api/salmon_controller.rb
@@ -1,6 +1,8 @@
 # frozen_string_literal: true
 
 class Api::SalmonController < Api::BaseController
+  include SignatureVerification
+
   before_action :set_account
   respond_to :txt
 
@@ -9,7 +11,7 @@ class Api::SalmonController < Api::BaseController
       process_salmon
       head 202
     elsif payload.present?
-      [signature_verification_failure_reason, 401]
+      render plain: signature_verification_failure_reason, status: 401
     else
       head 400
     end
diff --git a/spec/controllers/api/salmon_controller_spec.rb b/spec/controllers/api/salmon_controller_spec.rb
index 323d85b615e95efaecbfc21869138b2f4df1cf12..8af8b83a89a3225f558faa410938e90daf412f85 100644
--- a/spec/controllers/api/salmon_controller_spec.rb
+++ b/spec/controllers/api/salmon_controller_spec.rb
@@ -40,7 +40,7 @@ RSpec.describe Api::SalmonController, type: :controller do
       end
     end
 
-    context 'with invalid post data' do
+    context 'with empty post data' do
       before do
         request.env['RAW_POST_DATA'] = ''
         post :update, params: { id: account.id }
@@ -50,5 +50,19 @@ RSpec.describe Api::SalmonController, type: :controller do
         expect(response).to have_http_status(400)
       end
     end
+
+    context 'with invalid post data' do
+      before do
+        service = double(call: false)
+        allow(VerifySalmonService).to receive(:new).and_return(service)
+
+        request.env['RAW_POST_DATA'] = File.read(File.join(Rails.root, 'spec', 'fixtures', 'salmon', 'mention.xml'))
+        post :update, params: { id: account.id }
+      end
+
+      it 'returns http client error' do
+        expect(response).to have_http_status(401)
+      end
+    end
   end
 end