반응형

phpspec: A toolset for test-first development

phpspec is a PHP development tool for test-first development, otherwise known as (spec) behavior driven development. You end up writing code in small iterative steps, guided by the emerging design.

phpspec

 

반응형
반응형

Prerender: Let search engines crawl your JS apps

prerender

Prerender Service

This is a node server that uses phantomjs to render a javascript-rendered page as HTML. It should be used in conjunction with prerender_rails or prerender-node middleware to serve the rendered HTML to crawlers for SEO. You don't have to run this service on your own since I have it deployed on Heroku already. Get started in two lines of code using Rails or Node

It is also meant to be proxied through your server so that any relative links to things like CSS will work.

It is currently deployed at http://prerender.herokuapp.com, or you can deploy your own.

반응형
반응형

PHPMD: Find issues in your PHP code

phpmd

 

반응형
반응형

Monsta FTP — FTP cloudware

monsta ftp

 

반응형
반응형

Phalcon — Fastest PHP web framework

phalcon

반응형
반응형

 

http://www.daftlogic.com/projects-text-to-image.htm

 

PHP Text to Image

Change the settings and the click Create

Text The text to display
Rotation 0=normal 90=sideways
Font Size Points
Font
Padding Space around the image
Transparent
Fore Colour R G B (0-255)
Back Colour R G B (0-255)
(pop-up window)


Description

This script is a means to convert a string of text into an image. This has some simple uses such as displaying text such as email address that cannot be programmatically found. This can help to reduce the possibility of your email address being picked up by web crawlers and used for junk mail.

How To Use

To use the example interface above, simply modify or insert the string of text. You can edit any of the other settings, but this is optional.

Further Uses and Ideas:

How it Works:

The PHP Script

contact us for more information

Further Help

For anyone finding problems using this...

(1) Please test this example to ensure imagecreate works on your server...

<?php
header("Content-type: image/png");
$im = @imagecreate(110, 20)
or die("Cannot Initialize new GD image stream");
$background_color = imagecolorallocate($im, 0, 0, 0);
$text_color = imagecolorallocate($im, 233, 14, 91);
imagestring($im, 1, 5, 5, "A Simple Text String", $text_color);
imagepng($im);
imagedestroy($im);
?>

(2) Make sure to use the example at the top of this page by sending POST variables from your form. For example msg,font,size ...

Relevant Links

반응형
반응형

PHP Mobile Detect — Lightweight detection for mobile devices

Mobile Dev - PHP/Added on May 9, 2013/Add to favorites

PHP Mobile Detect is a lightweight PHP class for detecting mobile devices, including tablets and smartphones. It detects a mobile environment using the User-Agent string along with specific HTTP headers.

PHP Mobile Detect

 

반응형
반응형

php의 allow_url_fopen 설정의 보안 취약점에 주의하세요

BEST 질문 | 조회 2486
최근 발생하고 있는 홈페이지 변조나, 피싱 사이트로의 악용은 대부분 게시판의 취약점이나, php 의 취약점에 의해 발생되고 있습니다. 이중에 가장 빈번한 것이 php 의 외부 사이트 소스 실행 기능 (allow_url_fopen)으로 악의적인 프로그램이 실행되어져서 발생이 되고 있습니다.

이러한 문제로 인하여 한국정보보호진흥원에서는 allow_url_fopen 을 허용하지 않기를 권고 하고 있습니다.

allow_url_fopen 을 허용하게 되면 보안적으로 심각한 문제를 초래 할 수 있습니다.

해당 기능을 켜두게 되면, 원격에서 프로그램을 웹사이트에 삽입하여 실행(PHP injection), 대량으로 웹사이트를 변조 할 수 있게 되므로 어느날 갑자기, 홈페이지 화일이 통채로 지워지거나, 데이터베이스 내용이 모두 사라질수도 있습니다.

(관련 내용 URL : http://www.kisa.or.kr/kisa/notics/jsp/press_view.jsp?g_id=kisa&cgubun=&keyField=title&gid=kisa&b_gubun=04&cpage=1&page=1&dno=3&d_no=3&r_no=0&keyWord=)

저희 카페24에서는 기본적으로 해당 기능이 모두 off 로 설정이 되어 있으며, 따라서 고객님께서는 가급적 allow_url_fopen 기능이외에 다른 방법으로 구현을 하시거나, 아래의 예시와 같은 function 을 만들어서 사용하시는 것을 권고합니다. (HttpRequest, http_get, fsockopen 등의 함수로 구현이 가능합니다.)

(allow_url_fopen 기능이란 php 에서 include 를 사용할때 URL 방식으로 파일을 include 할수 있도록 해주는 기능입니다.)

(해당 내용이 이해가 되지 않거나, 보안의 위험성을 감수하더라도 반드시 allow_url_fopen 을 사용하셔야 한다면, 고객센터로 연락을 주시면 친절히 상담해 드립니다.)

-----------------------------------------------------------------------------------------

function get_url_fsockopen( $url ) {
$URL_parsed = parse_url($url);

$host = $URL_parsed["host"];
$port = $URL_parsed["port"];
if ($port==0)
$port = 80;

$path = $URL_parsed["path"];
if ($URL_parsed["query"] != "")
$path .= "?".$URL_parsed["query"];

$out = "GET $path HTTP/1.0\\r\\nHost: $host\\r\\n\\r\\n";

$fp = fsockopen($host, $port, $errno, $errstr, 30);
if (!$fp) {
echo "$errstr ($errno)<br>\\n";
} else {
fputs($fp, $out);
$body = false;
while (!feof($fp)) {
$s = fgets($fp, 128);
if ( $body )
$in .= $s;
if ( $s == "\\r\\n" )
$body = true;
}

fclose($fp);
echo $in;
}
}

-----------------------------------------------------------------------------------------
반응형

+ Recent posts