Add nonces to importers

git-svn-id: https://develop.svn.wordpress.org/trunk@5404 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren
2007-05-07 15:56:53 +00:00
parent 7c1f56b9b7
commit e8da828363
9 changed files with 57 additions and 26 deletions

View File

@@ -159,6 +159,7 @@ class WP_Import {
$authors = $this->get_wp_authors();
echo '<ol id="authors">';
echo '<form action="?import=wordpress&amp;step=2&amp;id=' . $this->id . '" method="post">';
wp_nonce_field('import-wordpress');
$j = -1;
foreach ($authors as $author) {
++ $j;
@@ -363,9 +364,11 @@ class WP_Import {
$this->greet();
break;
case 1 :
check_admin_referer('import-upload');
$this->select_authors();
break;
case 2:
check_admin_referer('import-wordpress');
$this->import();
break;
}