In order to allow remote logins into an Oracle database, you need to configure the database to use remote access, to do this you need to modify the init{sid}.ora file to have:
REMOTE_LOGIN_PASSWORDFILE = EXCLUSIVE
To create the password file, change to the ORACLE_HOME/dbs directory and run the orapwd program to create the remote access password file:
orapwd file=$ORACLE_HOME/dbs/orapw{sid} password={somepassword} entries=5