Hi,
This is a simple links sharing module with the help of this module site administrators can share their site links with the other site administrators. It provides a form where user can submit their links and reciprocal links. It provides a system settings form where admin can configure this module. It will help in the link building and link sharing site administrators can share their traffic with the help of this module. It will also help in the search engine optimization. Right now it is available only for Drupal 7
You will find my project here Exchange Links
Git Link : git clone http://git.drupal.org/sandbox/anwar_max/1428472.git exchange_links
Reviews of other projects:
http://drupal.org/node/1503992#comment-5855486
http://drupal.org/node/1511646#comment-5865106
http://drupal.org/node/1445414#comment-5865148
Manual Review of other projects:
http://drupal.org/node/1522456#comment-6071708
http://drupal.org/node/1289146#comment-6071750
http://drupal.org/node/1536854#comment-6071784
Manual Review of other projects:
http://drupal.org/node/1421554#comment-6099492
http://drupal.org/node/1624464#comment-6103966
http://drupal.org/node/1480562#comment-6104104
Manual Review of other projects:
http://drupal.org/node/1613094#comment-6112918
http://drupal.org/node/1632316#comment-6113042
http://drupal.org/node/1632294#comment-6113154
Manual Review of other projects:
http://drupal.org/node/1392210#comment-6113838
http://drupal.org/node/1576090#comment-6113904
http://drupal.org/node/1630118#comment-6114074
http://drupal.org/node/1626848#comment-6113972
| Comment | File | Size | Author |
|---|---|---|---|
| #11 | drupalcs-result.txt | 1.04 KB | klausi |
| #9 | systen.jpg | 129.13 KB | anwar_max |
| #8 | userform.jpg | 133.92 KB | anwar_max |
Comments
Comment #1
patrickd commentedwelcome,
I wonder if there's also a similar module doing this? (Could not find something after searching ~5min, maybe you could?)
Please take a moment to create a README.txt that follows the guidelines for in-project documentation.
Please take a moment to make your project page follow tips for a great project page.
It make's no sense to create a tag yet, you should only create tags if you're going to create a release (what is not possible yet).
while waiting for an in-depht review of your module you can start out fixing some coding style issues detected by automated tools:
http://ventral.org/pareview/httpgitdrupalorgsandboxanwarmax1428472git
You can also get a review bonus and we will come back to your application sooner.
regards
Comment #2
jygastaud commentedHi,
Please see result of automated review from ventral pareview and try to fix errors and warnings.
On the link, you should "repeat review" before change back status of the task to "need review".
Manual review:
- Every text display to users should be in t() function as in exchange_linkspage.inc.
- Be aware that html code should not be in t() -> Eg: Line 19 in exchange_links.module.
- Every comments should end by a "." , "?" or "!".
- Remove unnecessary comments as at line 90 in exchange_links.install.
Comment #3
chertzogI installed your module, and went looking for the configuration page, and couldnt find it. then i looked at your code, and noticed that your main configuration settings page is a MENU_LOCAL_TASK.
All you have to do is add separate menu item to be displayed on the configuration page, and then set the settings page as "MENU_DEFAULT_LOCAL_TASK" to make it be the first page that is shown.
Also, in the settings page you have the default text of the html code set as "
which comes from your .install file
This is also shown on the admin.inc file.
In your .pages.inc you have:
Your functions names should start with the name of your module to avoid namespace issues. So it should probably be something like :
Comment #4
anwar_maxHi,
All the above mentioned issues are fixed. Please have a look at Ventral Pareview.
Regards,
Anwar
Comment #5
anwar_maxComment #6
chhavik commentedManual Review :-
Comment #7
anwar_maxHi Chhavik,
Thanks,
Anwar
Comment #8
anwar_maxComment #9
anwar_maxComment #9.0
anwar_maxAdded reviews of other project.
Comment #9.1
anwar_maxReviewed one project.
Comment #10
anwar_maxAdded PAReview: review bonus
Comment #11
klausiThanks for your reviews, just make sure that you pick applications that did not get a review in a long time. When finishing your review comment also set the issue status either to "needs work" (you found some problems with the project) or "reviewed & tested by the community" (you found no flaws).
Review of the 7.x-1.x branch:
This automated report was generated with PAReview.sh, your friendly project application review script. You can also use the online version to check your project. Get a review bonus and we will come back to your application sooner.
manual review:
Removing review bonus tag, you can add it again if you have done another 3 reviews of other projects.
Comment #12
anwar_max1) exchange_links_install(): no need to set variables on installation, as you can use default values with variable_get() anyway.
++ Can you please suggest me best way for this?
2) exchange_links_uninstall(): why do you need the delete query on the vocabulary table?
++ I am deleting vocabulary and their terms.
3) "'access callback' => TRUE,"; a path in hook_menu() is unprotected? Are you doing that on purpose?
++ Fixed.
4) exchange_links_form(): all user facing text must run through t() for translation. Also make sure to use placeholders for dynamically inserted variables.
++ Fixed.
5) exchange_links_form(): don't create table markup yourself, use theme('table', ...) instead.
++ Fixed.
6) "'#value' => 'Add my link',": again, t() missing. Check all your strings in your module.
++ Fixed.
7) exchange_links_get_exchange_links(): doc block does not make sense. This is not a hook, why the "Implements"? See http://drupal.org/node/1354#functions . Also elsewhere.
++ Fixed.
8) exchange_links_get_exchange_links(): don't create list markup yourself, user theme('item_list', ...).
++ Fixed.
9) exchange_links_admin_links_form_submit(): use drupal_write_record() (schema validation) here instead of db_insert().
++ Fixed.
10) Same in exchange_links_view_links_form_submit() instead of db_update().
++ Fixed.
11) "module_invoke_all('exchange_links_operations'": if your module invokes its own hooks your should document them in an *.api.php file. See http://drupal.org/node/161085#api_php
++ Created a new exchange_links.api.php file to document hook.
12) exchange_links_overview(): $roles is never used.
++ Removed.
13) Please fix all doc blocks of your functions, they are useless right now.
++ Fixed.
Reviews of other projects:
http://drupal.org/node/1522456#comment-6071708
http://drupal.org/node/1289146#comment-6071750
http://drupal.org/node/1536854#comment-6071784
Comment #13
klausiPlease add all your reviews to the issue summary, also the new ones.
manual review:
<script>alert('XSS');</script>as site title or category I get a nasty javascript popup. This allows an attacker to pass malicious script code to the site administrator. You need to sanitize user provided input before printing it. See http://drupal.org/node/28984Removing review bonus tag, you can add it again if you have done another 3 reviews of other projects.
Comment #13.0
klausiReviewed one more project.
Comment #14
anwar_maxAdded reviews to the issue summary, also the new ones.
1. exchange_links_install(): just remove the variable_set() calls here.
alert('XSS');+ Now I am using only variable_get() function in other files so no need to remove variable_set() function from exchange_links_install().
2. exchange_links_uninstall(): The extra delete query on the taxonomy_vocabulary table is not necessary.
+ Removed.
3. exchange_links_form(): doc block is wrong, this is not a hook, this is a form builder function. See http://drupal.org/node/1354#forms Same on exchange_links_form_validate() and others. Please check all your function documentation.
+ Fixed.
4. 'Play fair link back!': all user facing text must run through t() for translation. Please check all your strings. Same in exchange_links_form_validate().
+ Fixed.
5. exchange_links_overview(): The output of this function is vulnerable to XSS exploits. If I enter
as site title or category I get a nasty javascript popup. This allows an attacker to pass malicious script code to the site administrator. You need to sanitize user provided input before printing it. See http://drupal.org/node/28984
+ Fixed.
Comment #15
klausiPlease don't remove the security tag, we keep that for statistics and to show examples of security problems.
Comment #16
klausimanual review:
Security issues are blockers, but otherwise this looks nearly ready. Removing review bonus tag, you can add it again if you have done another 3 reviews of other projects.
Comment #16.0
klausiAdded Manual Reviews of other projects
Comment #17
anwar_maxHi Klausi,
Thanks for your manual review :)
1) exchange_links_overview(): this is still vulnerable to XSS. Taxonomy term names are also user provided data and need to be sanitized.
+ Fixed.
Same for exchange_links_form(): all the user provided text settings retrieved with variable_get() should run through the appropriate sanitization function.
+ Fixed.
Comment #18
anwar_maxForgot to change status.
Now changing status.
Comment #19
klausimanual review:
So unfortunately I need to bump this back one more time. Almost there! Removing review bonus tag, you can add it again if you have done another 3 reviews of other projects.
Comment #19.0
klausiAdded review links
Comment #20
anwar_maxHi Klausi,
Thanks for quick response :)
1. exchange_links_form(): $link_category is only used on #options for a select form element, which sanitizes automatically. so you don't need the check_plain() on the items, double escaping is bad. See http://drupal.org/node/28984
+ Fixed.
2. exchange_links_form(): this is still vulnerable to XSS. The related links listing also includes the category which is not sanitized in exchange_links_get_exchange_links().
+ Fixed.
Comment #21
carlhinton commentedThis now seems to pass all tests at ventral
Comment #22
carlhinton commentedComment #23
Rahul Singh commentedTook a look, and this seems like RTBC for me.
Comment #24
klausiThanks for your contribution, anwar_max! Welcome to the community of project contributors on drupal.org.
I've granted you the git vetted user role which will let you promote this to a full project and also create new projects as either sandbox or "full" projects depending on which you feel is best.
Thanks, also, for your patience with the review process. Anyone is welcome to participate in the review process. Please consider reviewing other projects that are pending review. I encourage you to learn more about that process and join the group of reviewers.
As you continue to work on your module, keep in mind: Commit messages - providing history and credit and Release naming conventions.
Thanks to the dedicated reviewer(s) as well.
Comment #25.0
(not verified) commentedAdded manual review links