Overview

更新时间:
复制 MD 格式

After you integrate the slider captcha code on your frontend pages, integrate the slider captcha server-side SDK on your server.

Prerequisites

An AccessKey has been created for your Alibaba Cloud account. For more information, see Obtain an AccessKey.

Note

Do not use the AccessKey of your Alibaba Cloud account because a leak would compromise all your cloud resources. Instead, use the AccessKey of a RAM user to reduce this risk. To use Alibaba Cloud Captcha, grant the AliyunYundunAFSFullAccess permission to the RAM user.

Server-side code integration

Integrate the correct version of the slider captcha server-side SDK for your development environment as follows.

  1. Download the server-side SDK package for your programming language from the System Code Integration & Test page in the Alibaba Cloud Captcha console.

    Developer environment (Language)

    Server-side SDK package version requirements

    JAVA

    J2SE Development Kit (JDK) 1.5 or later

    .NET

    .NET Framework 4.0 or later

    PHP

    PHP 5.3 or later

    Python

    Python 2.7 or later

    Note

    Currently, server-side code integration for smart captcha is supported only for the Java, .NET, PHP, and Python SDKs. For other languages, call the AuthenticateSig OpenAPI operation. For more information, see AuthenticateSig - Server-side operation for slider and smart captcha.

  2. Unzip the SDK package and add it to your server-side project.

  3. Use the server-side code sample for your language to develop a handler class that processes requests from your frontend pages.

    Note

    Replace YOUR ACCESS_KEY in the sample code with your Alibaba Cloud AccessKey ID and YOUR ACCESS_SECRET with your AccessKey secret.

  4. Use the server-side code sample for your language to process the slider captcha result.

    Note

    When developing the result handler, handle any server-side faults.

References

For information about the server-side SDK integration methods for each development environment, see the following: