Saturday, 20 June 2015

Lets-Chat : Weekly update #5


Lets-chat





Here is my weekly update for GSoC project under +Tong Hui and +Mario Behling 





Issue #8 : Key generation for group OTR chat [1] 




  • Implemented the fingerprint of key using SHA-1 

  • Implemented the fingerprint of key using SHA-256

  • Implemented the fingerprints thus generated as 4 digit hex format

  • I will be pushing the fingerprints as 8-digit hex format in my next commit

  • Figured out that use of regex, instead of the loop I am using would be better as seen in TODO in my this week's commit 

  • Initially I was using nested loops to implement 4 digit hex format which I reduced to a loop for reducing complexity

  • Output is attached at [1]  as well as below for quick reference









Issue #19 Cannot create and enter in room [2]



  • +Tong Hui raised this bug , it was because of my commits that I pushed for Issue #17 generated by me

  • Fixed this bug

  • Closed Issue #19


Issue #17  [3]


  • I raised this issue as I felt it would be better for users to have password protected rooms by default

  • I pushed changed for this issue, but somehow it is giving a bug raised in Issue #19 at the moment



Issue #16 [4]


  • I raised this issue earlier, I tested it, worked fine

  •  +Tong Hui tested it as well and we have closed this one :)



I plan to work on Issue #15 [5] , I have already pushed some work :) and as suggested by my mentor +Tong Hui 





Saturday, 13 June 2015

Lets-chat : Weekly update #4

Lets - chat 




Here is my weekly update for GSoC project under +Tong Hui and +Mario Behling 





Issue #8 


  • Added execution time 
  • Made the key length as 1536 bits as required for OTR encryption
  • Planing to implement fingerprint of the key as suggested by my mentor +Tong Hui 


You can go through this issue at [1], and could see the snapshots of the terminal output after each commit for reference.





Issue  #15 




  • Raised this issue to implement encryption and decryption for OTR
  • Implemented Hash algorithm using crypto. SHA 512 using the private hex key generated by Diffie Hellman last week by me
  • Implemented AES encryption decryption on a sample text using Hmac . 



I am planing to work on improving issue #15 this week. [2] 






Issue #16



  • Raised this issue to have some more quotes for raptorize plugin 
  • Using this, when any of those quotes are messaged, a dinosaur appears which is quite interactive for end users
  • Added some frequently used words to raptorize 




[1]  https://github.com/beijinglug/lets-chat/issues/8
[2]  https://github.com/beijinglug/lets-chat/issues/15

Friday, 5 June 2015

Lets-chat : Weekly update GSoC #3

Lets-chat 



Here is the weekly update for my GSoC project, lets-chat under +Tong Hui and +Mario Behling 

  • Key - Generation : Issue #8 [1] 
As you could see, I initially used tried using random number generator [2] 








Then, I planned to use hardcore value : Number.MAX_VALUE and Number.MIN_VALUE instead of digits .  [3]









Later, I implemented key generation using crypto-js libraries [4] through Diffie Hellman as shown below :







Crypto-js libraries can be accessed at [5]

And later increased the key length as could be seen :









And added execution time [6]








Apart from Issue #8, I contributed to other issues as well :




Issue #10 [7] 

  • Issue #10 involved adding quick icons for reference, I provided one for key generation [8]




Issue #9 [9]
  • Issue #9 involves adding a menu for group encryption. There was a syntax error which I fixed. [10]


Issue #12 [11]

  • I raised this issue to have localised date in transcript. [12]


Issue #11 [13]

  • I raised this issue in order to have some hot keys in lets-chat. It is in progress, not yet resolved. 





[1]  https://github.com/beijinglug/lets-chat/issues/8

[2] https://github.com/beijinglug/lets-chat/commit/e71a1edb04d759914985c9df266f94bb9b147de6

[3]   https://github.com/beijinglug/lets-chat/commit/73074b0f0ec644074a3f40898f529939a42583d8

[4]  https://github.com/beijinglug/lets-chat/commit/77fe5f222bb8b20349c8f5e23862e59941c9c431

[5]  https://github.com/beijinglug/lets-chat/commit/4ef29d319b59640947f60873f6e7dd9c7fa930d2

[6]  https://github.com/beijinglug/lets-chat/commit/d2f6668e89ccfb439483b62d393184b522d7f9f9

[7]  https://github.com/fallacy321/lets-chat/commit/f19a99827d81536ccfb698478d0e9f28daef0b6d

[8]  https://github.com/beijinglug/lets-chat/issues/10

[9] https://github.com/fallacy321/lets-chat/commit/a370fc3b6dc61f63b178c705b462bf98b90ca174

[10]  https://github.com/beijinglug/lets-chat/issues/9

[11]  https://github.com/beijinglug/lets-chat/issues/12

[12] https://github.com/fallacy321/lets-chat/commit/6ed2ff992e4cf8b5f8d62ba05de0a7efd0b70e07

[13] https://github.com/beijinglug/lets-chat/issues/11

Friday, 29 May 2015

FOSSASIA : Week #2



Lets- chat



The coding period started on 25th May, 2015. 



Here is my weekly update :




  •  I got write access for blug chat, thanks to my awesome mentor +Tong Hui  I will be pushing directly now instead of pull request. 

  • I went through cryptocat as it has a OTR encrypted chat to provide an idea of how OTR works with chat application

  •  I tried improving the message part of blug in free time, and it seems initially that the message ID {{id}} that can be seen at app/core/messages.js , changes when the user logs off, so that can be used to display the online/offline status. However, later I realised it is dynamic in nature. Hence it would be better to have the status based on attribute such as time ( app/core/message.js ) {{posted}} 

  • I went through the issues related to 1:1 chat implement in xmpp and otr encryption in xmpp in lets-chat. [1]

  • Tong raised a few issues on blug-chat which are assigned to me and +苟颖琦 . I pushed some changes to contribute to the issue

  • On clicking on OTR messaging otr.html opens which is where OTR encryption could be tested 

  • I pushed a few javascript libraries as well meanwhile, which could help with the encrypted chats

  • SeedGeneration could provide assistance for the generation of seeds required to obtain fingerprints in random.js

  • As per my mentor's suggestion, I made a branch for my contributions : heenamahour/gsoc which is where I will be pushing the code from now on-wards

  • Also, I am trying to deploy lets chat at heroku at [2] . It works fine now. 




Looking forward to the key generation issue, lets hope I am able to resolve it :)





[3] my future contributions should be at branch heenamahour/gsoc instead of master : https://github.com/beijinglug/lets-chat/tree/heenamahour/gsoc

[4] Visit tonghuix.asia for getting in touch with the OTR encryption team :) 


I was a little bit occupied due to final year exams, practicals and other activities. I hope to be more active from next week on-wards. 


Happy summers !

Thursday, 30 April 2015

Google Summer of Code 2015 : FOSSASIA : Weekly update : 1



Lets-chat 




I got accepted for self-hosted online communities communication with OTR encryption : Back-end as a student developer under awesome mentors  +Tong Hui , +Mario Behling  and (soma) +Manuel Munz   under the organization +FOSSASIA . In fact,  +Tong Hui played a crucial role to encourage me to contribute to lets-chat. I am looking forward to work with him this summers. This is 






I will be first implementing the OTR encryption chat and then plans to link it with lets-chat .

Firstly, I would like to provide a brief description about OTR encryption, OTR encryption or Off The Record messaging will enable the users to have private conversations using lets-chat. OTR is an encryption tool for real-time chat, is easy to setup and provides a smooth user experience as well. Symmetric key cryptography is used through OTR encryption and hence the same key is used by the sender (Alice) and receiver (Bob) to encrypt the plaintext to ciphertext  and to decrypt the ciphertext to plaintext.   




Moreover, since the communication channel is insecure, for encrypting the communication, OTR uses Diffie-Hellman key exchange algorithm.  In short, Alice and Bob are able to exchange secret keys in such a way that they can derive a shared AES (Advanced Encryption Standard) key that is impossible for an intruder to decipher. This protocol hence ensures deniability and perfect forward secrecysince this protocol uses new key for each message. Interestingly, OTR encryption can be used on any internet chat protocol such as Google talk, lets-chat etc. 

I plan to implement the following features under FOSSASIA this summers under Tong Hui :
  • Generate long lived key : This step is going to be expensive as it might take seconds
  • Since OTR uses new key for each message, for each receiver, the sender wishes to communicate to, instantiate an OTR object
  • Implement function to send a message to the receiver
  • Implement function to receive a message to the sender
  • Ensure Symmetric key encryption
  • Ensuring the sender’s message is encrypted to obtain cipher text
  • Ensuring the receiver’s message is decrypted to obtain plain text
  • Close private connection when the chat is closed
  • Easy connectable API for front-end reuse


Note: I will be implementing the OTR encryption in group chats at first  and make sure that the code is efficient enough to use in lets-chat. 

After that I wish to implement the following :
  • Display status online/offline
  • Display fingerprints
  • Resolve bugs if any
  • Maintain proper documentation of back-end work



Looking forward to learn, code and develop this summer !




Some important links :



Thursday, 16 April 2015

Google Code In 2014 Wrap up : KDE

KDE : Experience freedom 


KDE is an international free software community producing an integrated set of cross-platform applications designed to run on LinuxFreeBSDSolarisMicrosoft Windows, and OS X systems.


 It is known for its Plasma Desktop, a desktop environment which is provided as the default work environment on many Linux distributions, such as openSUSEMageia and Kubuntu. 








KDE project serves as an umbrella project for many standalone applications and smaller projects that are based on KDE technology. Recently KDE participated in Google Code In to provide young contributors an opportunity to get involved with KDE and inspire them to get involved with open source. 


During December, KDE managed to create over 100 tasks, with over 29 mentors. 

It gradually increased to over 277 tasks by the next month. It was great to see such an active contribution by the students to KDE and the mentors made sure the students are well equipped with the tasks. Marble managed to create maximum tasks among the KDE projects with over 50 out of 277  tasks. 



Also, for the young contributors, KDE provided over 65 beginner tasks which helped them to get involved with open source.

 Later, the students were expected to go ahead with non-beginner tasks to help them foster their skills. KDE provided tasks of varied types ranging from code, documentation/training, design, quality assurance and outreach/research. 


Some twitter follow ups : 








It was overwhelming to see a synchronous and healthy student mentor relationship while Google Code In. 

The students performed well with the highest score by Mikhail Ivchenko and second highest by Ilya Kowalewski . 

We thanks Google Code In to help KDE to encourage young students to get involved with KDE. 



-Heena Mahour 
co-administrator of GCI 2014 under KDE

Sunday, 12 April 2015

Vagrant: Why and how



Why I am using Vagrant?


  • Vagrant provides easy to configure, reproducible, and portable work environments built on top of industry-standard technology and controlled by a single consistent workflow to help maximize the productivity and flexibility of you and your team.

  • Using the vagrantFile, the project developers are able to run the code in the same environment, against the same dependencies, all configured the same way.




Purpose of Vagrantfile :



  • Mark the root directory of your project. A lot of the configuration of Vagrant is relative to this root directory.

  • Describe the kind of machine and resources you need to run your project, as well as what software to install and how you want to access it.

How to build Vagrant?


  • Make sure your system is updated. Since I was earlier using Kubuntu 13.04 which is not supported by vagrant, I upgraded Kubuntu 13.04 to Kubuntu 13.10 to Kubuntu 14.04 to be able to run it

  • Check your system and download vagrant through this link 

  • Perform the following bash commands :
$ mkdir vagrant_directory
$cd vagrant_directory
$vagrant init
$vagrant box add ubuntu/trusty64


  • Now, open the vagrantFile and do the following :

Vagrant.configure("2") do |config|
config.vm.box = "ubuntu/trusty64
  • Now, open and terminal and do the following :
$vagrant up 
To prove that it is running, you can SSH into the machine:
$ vagrant ssh
To access the vagrantfile of my system, visit github: fallacy321/vagrant

To have a look at my terminal : pastebin 


Thursday, 19 March 2015

FOSSASIA 2015 : Summary

FOSSASIA 2015



Recently I visited Singapore and attended FOSSASIA 2015 talks and workshops. It was a really nice experience and I learnt a lot !




What I did?


I was selected as a speaker and presented a talk on KDE regarding the open source contribution made by +The KDE Community with respect to my journey as a Season of KDE student to Google Code In co-administrator. 

I discussed about the recent trends in our community outreach program (SoK) as well as how vast KDE is. 

I also discussed about the plasma development in KDE and how I ported the plasmoids to plasma2. 

I also discussed about the tasks created by KDE in +Google Code-in , thanks to the admin team and constructive mentors. I also discussed a bit about +KDE-Edu game pairs.










I also organised a GSoC session ( thanks to +Mario Behling for suggesting the idea :) ) .

 It went a success as it was proceeded with how GSoC works, how KDE contributes to GSoC, the attendees presented their views as well and discussed about their open source contributions during the session. 

It was nice to see so many mentors, students and new contributors during the session.










How it helps KDE?



My talk helped to spread an information about the programs and projects KDE is involved with. New contributors were keen to get involved with KDE as well.

 I also discussed about Season of KDE to spread information about the same.



Some twitter follow ups:


























What I learnt?


I realized a team work, that is, contribution in collaboration could provide magical outcomes. One has to be precise while presenting a talk as time is a constraint. 
Moreover, I also met some great contributors like +Handoko Suwono , +Dhruv Goel , +Nikunj Thakkar and many others across the globe and hopefully I will stay connected to them in the long run .I also got to learn about the vast projects developers are getting involved with in different organizations and it helps one to stay motivated to open source and KDE ofcourse ! :)